-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Add arrows at the end of x and y axis #1740
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
@hadley what do you think of this? It's rather straightforward to add an arrow argument to |
Dear @hadley, perhaps line_type in element_line() could be changed from: "An integer or name: 0 = blank, 1 = solid, 2 = dashed, 3 = dotted, 4 = dotdash, 5 = longdash, 6 = two dash", to 1.... through 7= solidarrow ? |
That would be the wrong approach - the arguments should map directly to polylineGrob so that |
My only concern would be that there might be clipping issues — I can't remember where/when the axes are drawn. If that's not a problem, go ahead and add it. |
My cursory investigation shows no clipping problems so I'll make a PR |
Add arrow argument to element_line(). Fixes #1740
Thanks for the arrows. They look great ! Today, I have replicated the chart in RStudio with arrows using theme() and element_line(arrow=arrow()). Yet, while using theme_bw() it did not work. Is the element_line an attribute to one theme only, or all themes can make use of it? Question: how I can get a clear background on the chart (without gray background and grid)? Best, |
@adamkk a better place for questions of that nature is the ggplot2 mailing list |
Hi,
After long time searching this issue, I need to ask this request. In my academic work, each chart needs to have x and y axis ending in arrows. Example: http://www.policonomics.com/supply-and-demand/
How can I add this to my ggplot2 charts?
Best,
The text was updated successfully, but these errors were encountered: