indexing allowed for points and lines#420
Conversation
jiwalker-usgs
left a comment
There was a problem hiding this comment.
I think this is fine, I'm just wondering if we will have an issue with functions like this going forward.
R/set_args.R
Outdated
| config_args <- config(fun.name, custom.config = custom.config) | ||
| user_args <- function_args(name=fun.name, package=package, ...) | ||
|
|
||
| if(fun.name %in% c('points', 'lines')){ |
There was a problem hiding this comment.
I think this should maybe be in function_args rather than here. I worry that adding special cases in set_args will complicate this function beyond where it is now.
|
I agree w/ what @jiwalker-usgs said. this looks fine to me too, but we should (as in the past) just be able to pass the args on to points w/ y=NULL and have that function handle it appropriately. |
|
@jread-usgs have points.gsplot handle it appropriately or graphics::points? The issue seems to be that we never pass it to points.default which calls plot.xy and handles this issue of y=NULL. |
|
I meant |
|
I guess I'm struggling with the |
Does not label x axis as "Index" and y with range. Works for logged axes and keeps user-specified axis labels. Also works with dates and other classes. It also works for
lines.See #245
Originally, I had implemented this using
xy.coordssince that is whatpoints.defaultandlines.defaultcall, but if coerces data into numeric.