Skip to content
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

Version 2.0.0 broke autoplot() #1458

Closed
ghuiber opened this issue Dec 29, 2015 · 6 comments
Closed

Version 2.0.0 broke autoplot() #1458

ghuiber opened this issue Dec 29, 2015 · 6 comments

Comments

@ghuiber
Copy link

ghuiber commented Dec 29, 2015

The example shown here no longer works:

> library(ggfortify)
> library(survival)
> fit <- survfit(Surv(time, status) ~ sex, data = lung)
> autoplot(fit)
Error in get(x, envir = this, inherits = inh)(this, ...) : 
  unused argument (TRUE)

This is with R 3.2.3 and ggplot2 updated today.

@yutannihilation
Copy link
Member

I think you should update ggfortify to v0.1.0, which is compatible with ggplot2 v2.0.0 :)

@ghuiber
Copy link
Author

ghuiber commented Dec 30, 2015

That is the version I have. See below:

> library(ggfortify)
> library(survival)
> fit <- survfit(Surv(time, status) ~ sex, data = lung)
> autoplot(fit)
Error in get(x, envir = this, inherits = inh)(this, ...) : 
  unused argument (TRUE)
> print(sessionInfo())
R version 3.2.3 (2015-12-10)
Platform: x86_64-apple-darwin13.4.0 (64-bit)
Running under: OS X 10.10.5 (Yosemite)

locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods  
[7] base     

other attached packages:
[1] survival_2.38-3 ggfortify_0.1.0 ggplot2_2.0.0  
[4] proto_0.3-10    MASS_7.3-45    

loaded via a namespace (and not attached):
 [1] Rcpp_0.12.2      tidyr_0.3.1      dplyr_0.4.3     
 [4] assertthat_0.1   grid_3.2.3       plyr_1.8.3      
 [7] R6_2.1.1         gtable_0.1.2     DBI_0.3.1.9008  
[10] magrittr_1.5     scales_0.3.0     splines_3.2.3   
[13] tools_3.2.3      munsell_0.4.2    parallel_3.2.3  
[16] colorspace_1.2-6 gridExtra_2.0.0 

@hadley hadley closed this as completed Dec 30, 2015
@yutannihilation
Copy link
Member

@ghuiber
Sorry for my misunderstanding. I did reproduce this error. It may be better to report the issue on ggfortify's repo.

The error seems to occur here: https://github.com/hadley/ggplot2/blob/d36e9193479ad43aac0842c07582afa3dd1a538a/R/layer.r#L58

@ghuiber
Copy link
Author

ghuiber commented Jan 1, 2016

I did install_github() on both ggplot2 and ggfortify after @hadley closed this issue; autoplot() works again. I expect the CRAN versions will catch up soon enough.

@yutannihilation
Copy link
Member

Hmm... I guess now you cannot reproduce this any more even if you use the CRAN versions. I can't.
Something may be wrong with some package in the dependency chain.

Anyway, it's good that the issue has been fixed! 👍

@sciatro
Copy link

sciatro commented Feb 9, 2016

I seem to be getting this error despite using v2 and v0.1. Here's the reproduction & session info:

> library(survival)
> library(ggfortify)
Loading required package: proto
Loading required package: ggplot2
> autoplot(survfit(Surv(time, status) ~ sex, data = lung))
Error in get(x, envir = this, inherits = inh)(this, ...) : 
  unused argument (TRUE)
> sessionInfo()
R version 3.2.3 (2015-12-10)
Platform: x86_64-apple-darwin13.4.0 (64-bit)
Running under: OS X 10.9.5 (Mavericks)

locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
[1] ggfortify_0.1.0 ggplot2_2.0.0   proto_0.3-10    survival_2.38-3

loaded via a namespace (and not attached):
 [1] Rcpp_0.12.1      tidyr_0.3.1      dplyr_0.4.3      assertthat_0.1  
 [5] grid_3.2.3       plyr_1.8.3       R6_2.1.1         gtable_0.1.2    
 [9] DBI_0.3.1        magrittr_1.5     scales_0.3.0     splines_3.2.3   
[13] tools_3.2.3      munsell_0.4.2    parallel_3.2.3   colorspace_1.2-6
[17] gridExtra_2.0.0 

@lock lock bot locked as resolved and limited conversation to collaborators Jun 19, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants