ggplot2 2.2.1.9000

Create issue
Issue #2 new
Former user created an issue

Hello Nicholas,

This is just to let you know that there is a possible problem in the horizon. I am writing a book and noticed that my ggtern examples had stopped working when I updated 'ggplot2' to the development version now in Github. I am not sure if this is a bug that needs to be fixed in your package or in 'ggplot2' itself.

The current development version of 'ggplot2' breaks ggtern, the example given below results in the following message: Error in f(..., self = self) : unused argument (<environment>)

library(ggtern)
test.data <- data.frame(x = 0.5, y = 0.5, z = 0.5)
ggtern(data=test.data,
       aes(x=R, y=G, z=B)) +
  geom_point()

with

sessionInfo()
R version 3.4.1 (2017-06-30)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows >= 8 x64 (build 9200)

Matrix products: default

locale:
[1] LC_COLLATE=English_United Kingdom.1252  LC_CTYPE=English_United Kingdom.1252   
[3] LC_MONETARY=English_United Kingdom.1252 LC_NUMERIC=C                           
[5] LC_TIME=English_United Kingdom.1252    

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

other attached packages:
[1] ggtern_2.2.1       ggplot2_2.2.1.9000 devtools_1.13.3   

loaded via a namespace (and not attached):
 [1] Rcpp_0.12.12        magrittr_1.5        MASS_7.3-47         munsell_0.4.3      
 [5] colorspace_1.3-2    lattice_0.20-35     rlang_0.1.1         stringr_1.2.0      
 [9] plyr_1.8.4          tools_3.4.1         grid_3.4.1          gtable_0.2.0       
[13] withr_2.0.0         yaml_2.1.14         lazyeval_0.2.0      digest_0.6.12      
[17] tibble_1.3.3        bayesm_3.1-0.1      latex2exp_0.4.0     gridExtra_2.2.1    
[21] tensorA_0.36        energy_1.7-0        compositions_1.40-1 memoise_1.1.0      
[25] robustbase_0.92-7   stringi_1.1.5       compiler_3.4.1      DEoptimR_1.0-8     
[29] scales_0.4.1.9002   boot_1.3-19         proto_1.0.0        
> 

You may want to discuss this with the maintainer of 'ggplot2' in good time.

Best regards,

Pedro.

Comments (5)

  1. Nicholas Hamilton repo owner

    Hi Thomas,

    The bitbucket version should have this fixed, I'll be pushing to CRAN probably tonight.

    Apologies for the delay and inconvenience.

    Regards,

    NH

  2. Thomas Hackl

    Didn't get around to test it sooner, sorry. I've upgraded to ggplot 3.0.0 in the meantime. With that version and the latest ggtern, the issue is fixed. Thanks!

  3. Benjamin LeRoy

    Hi Nicholas,

    The update of ggplot2 to 3.3.0 has also cause error relative to ggtern.

    With the same example:

     library(ggtern)
     test.data <- data.frame(x = 0.5, y = 0.5, z = 0.5)
     ggtern(data=test.data,
            aes(x=x, y=y, z=z)) +
         geom_point()
    

    one now gets:

    Error: $ operator is invalid for atomic vectors
    

    Here’s my sessionInfo() for good measure:

    R version 3.6.1 (2019-07-05)
    Platform: x86_64-apple-darwin15.6.0 (64-bit)
    Running under: macOS Catalina 10.15.3
    
    Matrix products: default
    BLAS:   /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
    LAPACK: /Library/Frameworks/R.framework/Versions/3.6/Resources/lib/libRlapack.dylib
    
    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] ggtern_3.1.0  ggplot2_3.3.0
    
    loaded via a namespace (and not attached):
     [1] Rcpp_1.0.3          rstudioapi_0.11     magrittr_1.5       
     [4] MASS_7.3-51.4       tidyselect_1.0.0    munsell_0.5.0      
     [7] colorspace_1.4-1    lattice_0.20-38     R6_2.4.1           
    [10] rlang_0.4.5         stringr_1.4.0       plyr_1.8.6         
    [13] dplyr_0.8.4         tools_3.6.1         grid_3.6.1         
    [16] gtable_0.3.0        withr_2.1.2         yaml_2.2.0         
    [19] assertthat_0.2.1    bayesm_3.1-4        tibble_2.1.3       
    [22] lifecycle_0.2.0     crayon_1.3.4        latex2exp_0.4.0    
    [25] tensorA_0.36.1      gridExtra_2.3       farver_2.0.3       
    [28] purrr_0.3.3         compositions_1.40-3 robustbase_0.93-5  
    [31] glue_1.3.1          labeling_0.3        stringi_1.4.6      
    [34] DEoptimR_1.0-8      compiler_3.6.1      pillar_1.4.3       
    [37] scales_1.1.0        pkgconfig_2.0.3     proto_1.0.0 
    

  4. Log in to comment