-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Add explicit 'parameters' arg to coord_map() in response to PR #1699 #1729
Conversation
Can you fix the examples and add a bullet point to NEWS please? |
Instead of modifying the original examples, I made coord_map() backwards-compatible by reinstating the ... argument. NEWS.md file is updated to reflect the coord_map() fix. |
@@ -21,7 +21,8 @@ | |||
#' @export | |||
#' @param projection projection to use, see | |||
#' \code{\link[mapproj]{mapproject}} for list | |||
#' @param ... other arguments passed on to | |||
#' @param ... other arguments passed on to mapproject. Ignored if the \code{parameters} argument is present. | |||
#' @param parameters optional numeric vector of parameters for use with the projection argument. This argument is optional only in the sense that certain projections do not require additional parameters. Passed to |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you please break this line up? Otherwise looks good.
Added line breaks to coord_map() docs. Should be ready to merge in. |
Thanks! |
This old issue has been automatically locked. If you believe you have found a related problem, please file a new issue (with reprex) and link to this issue. https://reprex.tidyverse.org/ |
I replaced the ... argument in coord_map() with parameters = NULL and added a new example in its help file for a projection that needs a 'parameters' argument. This fixes the bug mentioned in PR #1699.
In the previous version of coord_map(), the ... argument only served to pass the 'parameters' argument to mapproj::mapproject(), so it can be safely removed. I also added documentation about the new 'parameters' argument in coord_map().
P.S. I've now realized the proper workflow would have been to modify the original pull request at #1699 , but it's too late now.