geom_waffle() not found
vcollier13 opened this issue · 17 comments
library(tibble)
library(waffle)
library(ggplot2)
After installing waffle and dependent libraries, I tried using the sample code below but receive error: "Error in geom_waffle(color = "white", size = 1.125, n_rows = 6) :
could not find function "geom_waffle""
##############
tibble(
parts = factor(rep(month.abb[1:3], 3), levels=month.abb[1:3]),
values = c(10, 20, 30, 6, 14, 40, 30, 20, 10),
fct = c(rep("Thing 1", 3), rep("Thing 2", 3), rep("Thing 3", 3))
) -> xdf
ggplot(xdf, aes(fill=parts, values=values)) +
geom_waffle(color = "white", size=1.125, n_rows = 6) +
facet_wrap(~fct, ncol=1) +
scale_x_discrete(expand=c(0,0)) +
scale_y_discrete(expand=c(0,0)) +
ggthemes::scale_fill_tableau(name=NULL) +
coord_equal() +
labs(
title = "Faceted Waffle Geoms"
) +
theme_ipsum_rc(grid="") +
theme_enhance_waffle()
Please provide your session info. I use geom_waffle()
weekly.
I, too, am getting an error "could not find function "geom_waffle"". Here is my session info. Thank you for any guidance you offer:
R version 4.0.0 (2020-04-24)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 10 x64 (build 17763)
Matrix products: default
locale:
[1] LC_COLLATE=English_United States.1252 LC_CTYPE=English_United States.1252
[3] LC_MONETARY=English_United States.1252 LC_NUMERIC=C
[5] LC_TIME=English_United States.1252
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] dplyr_0.8.5 waffle_0.7.0 ggplot2_3.3.0 hrbrthemes_0.8.0
loaded via a namespace (and not attached):
[1] Rcpp_1.0.4.6 pillar_1.4.4 compiler_4.0.0 RColorBrewer_1.1-2
[5] tools_4.0.0 extrafont_0.17 digest_0.6.25 evaluate_0.14
[9] lifecycle_0.2.0 tibble_3.0.1 gtable_0.3.0 pkgconfig_2.0.3
[13] rlang_0.4.5 cli_2.0.2 rstudioapi_0.11 xfun_0.13
[17] gridExtra_2.3 Rttf2pt1_1.3.8 withr_2.2.0 knitr_1.28
[21] systemfonts_0.2.1 gdtools_0.2.2 vctrs_0.2.4 grid_4.0.0
[25] tidyselect_1.0.0 glue_1.4.0 R6_2.4.1 fansi_0.4.1
[29] rmarkdown_2.1 purrr_0.3.4 extrafontdb_1.0 magrittr_1.5
[33] scales_1.1.0 ellipsis_0.3.0 htmltools_0.4.0 assertthat_0.2.1
[37] colorspace_1.4-1 munsell_0.5.0 crayon_1.3.4
Hi there, I got the same error, could not find function "geom_waffle"
. My session information is as follows
R version 4.0.2 (2020-06-22)
Platform: x86_64-apple-darwin17.0 (64-bit)
Running under: macOS Catalina 10.15.5
Matrix products: default
BLAS: /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/4.0/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] tidyr_1.1.0 forcats_0.5.0 tibble_3.0.3 extrafont_0.17
[5] hrbrthemes_0.8.0 waffle_1.0.1 ggplot2_3.3.2 lubridate_1.7.9
[9] dplyr_1.0.0
loaded via a namespace (and not attached):
[1] tidyselect_1.1.0 xfun_0.15 remotes_2.1.1 purrr_0.3.4
[5] colorspace_1.4-1 vctrs_0.3.1 generics_0.0.2 testthat_2.3.2
[9] usethis_1.6.1 htmltools_0.5.0 utf8_1.1.4 rlang_0.4.7
[13] pkgbuild_1.1.0 pillar_1.4.6 glue_1.4.1 withr_2.2.0
[17] gdtools_0.2.2 RColorBrewer_1.1-2 sessioninfo_1.1.1 lifecycle_0.2.0
[21] munsell_0.5.0 gtable_0.3.0 devtools_2.3.0 evaluate_0.14
[25] memoise_1.1.0 knitr_1.29 callr_3.4.3 ps_1.3.3
[29] curl_4.3 fansi_0.4.1 Rttf2pt1_1.3.8 Rcpp_1.0.5
[33] scales_1.1.1 backports_1.1.8 desc_1.2.0 pkgload_1.1.0
[37] farver_2.0.3 fs_1.4.2 systemfonts_0.2.3 gridExtra_2.3
[41] digest_0.6.25 processx_3.4.3 grid_4.0.2 rprojroot_1.3-2
[45] cli_2.0.2 tools_4.0.2 magrittr_1.5 crayon_1.3.4
[49] extrafontdb_1.0 pkgconfig_2.0.3 ellipsis_0.3.1 prettyunits_1.1.1
[53] assertthat_0.2.1 rmarkdown_2.3 rstudioapi_0.11 R6_2.4.1
[57] compiler_4.0.2
Thanks! The problem disappeared after I reinstalled rStudio.
Hi, I just reinstalled RStudio and my profile, it seems to work now so you can close this out, thanks! Vanessa
…
________________________________ From: boB Rudis notifications@github.com Sent: Tuesday, April 28, 2020 10:16 AM To: hrbrmstr/waffle waffle@noreply.github.com Cc: Vanessa Collier vcollie2@jhu.edu; Author author@noreply.github.com Subject: Re: [hrbrmstr/waffle] geom_waffle() not found (#76) Please provide your session info. I use geom_waffle() weekly. — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub<#76 (comment)>, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ANJM2AHATUZOL4NKBAZMPJDRO4FP5ANCNFSM4MNYZYGA.
could not find function "geom_waffle"
The problem is still there tired reinstalling no luck.
os - Mac os
Hello, I am receiving the same problem.
I have installed waffle from github and reinstalled Rstudio to no avail... please help!
sessionInfo()
R version 4.0.3 (2020-10-10)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 10 x64 (build 18363)
Matrix products: default
locale:
[1] LC_COLLATE=English_United Kingdom.1252 LC_CTYPE=English_United Kingdom.1252 LC_MONETARY=English_United Kingdom.1252
[4] LC_NUMERIC=C LC_TIME=English_United Kingdom.1252
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] waffle_0.7.0 exactextractr_0.5.1 raster_3.4-5 sp_1.4-4 stringr_1.4.0 stringi_1.5.3
[7] dplyr_1.0.2 sf_0.9-6 ggpubr_0.4.0 reshape2_1.4.4 ggplot2_3.3.2
loaded via a namespace (and not attached):
[1] tidyselect_1.1.0 purrr_0.3.4 ggthemes_4.2.0 lattice_0.20-41 haven_2.3.1 carData_3.0-4
[7] colorspace_2.0-0 vctrs_0.3.5 generics_0.1.0 rlang_0.4.9 e1071_1.7-4 pillar_1.4.7
[13] foreign_0.8-80 glue_1.4.2 withr_2.3.0 DBI_1.1.0 RColorBrewer_1.1-2 readxl_1.3.1
[19] lifecycle_0.2.0 plyr_1.8.6 munsell_0.5.0 ggsignif_0.6.0 gtable_0.3.0 cellranger_1.1.0
[25] zip_2.1.1 codetools_0.2-16 rio_0.5.16 forcats_0.5.0 extrafont_0.17 curl_4.3
[31] class_7.3-17 Rttf2pt1_1.3.8 broom_0.7.2 Rcpp_1.0.5 KernSmooth_2.23-17 backports_1.2.0
[37] scales_1.1.1 classInt_0.4-3 abind_1.4-5 gridExtra_2.3 hms_0.5.3 openxlsx_4.2.3
[43] rstatix_0.6.0 grid_4.0.3 tools_4.0.3 magrittr_2.0.1 tibble_3.0.4 extrafontdb_1.0
[49] crayon_1.3.4 car_3.0-10 tidyr_1.1.2 pkgconfig_2.0.3 ellipsis_0.3.1 data.table_1.13.2
[55] rstudioapi_0.13 R6_2.5.0 units_0.6-7 compiler_4.0.3
I literally just (now) did this:
Sys.time()
## [1] "2020-12-04 15:50:24 EST"
remotes::install_github("hrbrmstr/waffle")
## Using github PAT from envvar GITHUB_PAT
## Downloading GitHub repo hrbrmstr/waffle@HEAD
## ✓ checking for file ‘/private/var/folders/bx/41ph1lms22q9mc83j5tx4bg80000gn/T/Rtmp1Bm1wX/remotesf84647eba317/hrbrmstr-waffle-3f61463/DESCRIPTION’ ...
## ─ preparing ‘waffle’:
## ✓ checking DESCRIPTION meta-information ...
## ─ checking for LF line-endings in source and make files and shell scripts
## ─ checking for empty or unneeded directories
## ─ building ‘waffle_1.0.1.tar.gz’
##
## * installing *source* package ‘waffle’ ...
## ** using staged installation
## ** R
## ** inst
## ** byte-compile and prepare package for lazy loading
## ** help
## *** installing help indices
## ** building package indices
## ** installing vignettes
## ** testing if installed package can be loaded from temporary location
## ** testing if installed package can be loaded from final location
## ** testing if installed package keeps a record of temporary installation path
## * DONE (waffle)
library(waffle)
## Loading required package: ggplot2
?geom_waffle
I am at a loss as to what might be going wrong in the steps folks are taking.
Boom! thanks @hrbrmstr .. must have been the call to install via the command line which prompted a number of package updates..anyway, all working now. Much appreciated.
Doing remotes::install_github("hrbrmstr/waffle")
and restarting the R session did it for me.
Doing
remotes::install_github("hrbrmstr/waffle")
and restarting the R session did it for me.
That's really worked!
Doing remotes::install_github("hrbrmstr/waffle") and restarting the R session did it for me.
worked for me
Doing
remotes::install_github("hrbrmstr/waffle")
and restarting the R session did it for me.
worked for me too
Also ran into this; there was an additional issue with the remotes::install_github (probably due to corproate firewall) so crossposting it here for reference:
Issue: forestgeo/learn#102
Fix: options(download.file.method = "wininet")
Restarting the session wasn't necessary in my case
None of the options here worked for me, even after updating R, Rstudio, using the direct install from github, etc...
However directly calling the function from the package did the trick!
Use
waffle::geom_waffle()