You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.
See below. I think it's against the principles laid out in the tidyverse principle book, it can be fixed by using c(NA_real_, NA_real_) as a default.
The issue arose as I was writing a wrapper around qplot and it choked when passing the parameters xlim = xlim, ylim = ylim.
library(ggplot2)
# works
qplot(Sepal.Width, Sepal.Length, data=iris)
# doesn't work
qplot(Sepal.Width, Sepal.Length, data=iris, xlim= c(NA,NA))
#> Error in UseMethod("limits"): no applicable method for 'limits' applied to an object of class "logical"# works
qplot(Sepal.Width, Sepal.Length, data=iris, xlim= c(NA_real_,NA_real_))
See below. I think it's against the principles laid out in the tidyverse principle book, it can be fixed by using
c(NA_real_, NA_real_)
as a default.The issue arose as I was writing a wrapper around
qplot
and it choked when passing the parametersxlim = xlim, ylim = ylim
.Created on 2020-05-25 by the reprex package (v0.3.0)
The text was updated successfully, but these errors were encountered: