You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

R版本更新后ggcyto函数运行报错求助

ggcyto报错:attempt to apply non-function 问题求助

更新R版本后,运行ggcyto包手册中的示例代码时出现报错,无法正常使用函数。

运行代码:

data(GvHD)
fs <- GvHD[1:3]
#construct the `ggcyto` object (inherits from `ggplot` class)
p <- ggcyto(fs, aes(x = `FSC-H`)) 

报错信息:

Error in guides$setup(scales, aesthetics, default = params$guide_default %||% : attempt to apply non-function

已尝试的解决方法:删除R、RStudio以及/Library/Frameworks/R.framework/Versions/4.2/Resources/library下的所有相关文件,重新安装后问题依旧。

以下是两次更新包前后的sessionInfo()输出:

更新前sessionInfo()

> sessionInfo()
R version 4.0.3 (2020-10-10)
Platform: x86_64-apple-darwin17.0 (64-bit)
Running under: macOS Catalina 10.15.7

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] ggcyto_1.18.0            flowWorkspace_4.2.0      ncdfFlow_2.36.0          BH_1.84.0-0              RcppArmadillo_0.12.8.4.0
[6] flowCore_2.2.0           ggplot2_3.5.1           

loaded via a namespace (and not attached):
 [1] tidyselect_1.2.1    lattice_0.22-6      colorspace_2.1-0    vctrs_0.6.5         generics_0.1.3      stats4_4.0.3        base64enc_0.1-3    
 [8] XML_3.99-0.9        utf8_1.2.4          rlang_1.1.4         hexbin_1.28.3       pillar_1.9.0        glue_1.7.0          withr_3.0.0        
[15] aws.s3_0.3.21       Rgraphviz_2.34.0    BiocGenerics_0.36.1 RColorBrewer_1.1-3  plyr_1.8.9          jpeg_0.1-10         matrixStats_1.3.0  
[22] lifecycle_1.0.4     zlibbioc_1.36.0     RProtoBufLib_2.2.0  munsell_0.5.1       gtable_0.3.5        cytolib_2.2.1       labeling_0.4.3     
[29] latticeExtra_0.6-30 Biobase_2.50.0      parallel_4.0.3      curl_5.2.1          fansi_1.0.6         Rcpp_1.0.12         scales_1.3.0       
[36] BiocManager_1.30.23 S4Vectors_0.28.1    RcppParallel_5.1.7  graph_1.68.0        farver_2.1.2        deldir_2.0-4        interp_1.1-6       
[43] gridExtra_2.3       png_0.1-8           digest_0.6.35       dplyr_1.1.4         grid_4.0.3          cli_3.6.2           tools_4.0.3        
[50] magrittr_2.0.3      tibble_3.2.1        aws.signature_0.6.0 pkgconfig_2.0.3     data.table_1.15.4   xml2_1.3.3          httr_1.4.7         
[57] R6_2.5.1            compiler_4.0.3 

更新多个包后sessionInfo()(仍报错)

R version 4.2.3 (2023-03-15)
Platform: x86_64-apple-darwin17.0 (64-bit)
Running under: macOS Catalina 10.15.7

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.2/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] ggcyto_1.26.4        flowWorkspace_4.10.1 ncdfFlow_2.44.0      BH_1.84.0-0          flowCore_2.10.0      ggplot2_3.5.1        

loaded via a namespace (and not attached):
 [1] Rcpp_1.0.12         BiocManager_1.30.23 plyr_1.8.9          pillar_1.9.0        compiler_4.2.3      cytolib_2.10.1      RColorBrewer_1.1-3  tools_4.2.3         zlibbioc_1.44.0     lattice_0.22-6     
[11] lifecycle_1.0.4     tibble_3.2.1        gtable_0.3.5        pkgconfig_2.0.3     rlang_1.1.4         graph_1.76.0        cli_3.6.2           Rgraphviz_2.42.0    hexbin_1.28.3       gridExtra_2.3      
[21] withr_3.0.0         dplyr_1.1.4         generics_0.1.3      S4Vectors_0.36.2    vctrs_0.6.5         stats4_4.2.3        grid_4.2.3          tidyselect_1.2.1    glue_1.7.0          data.table_1.15.4  
[31] Biobase_2.58.0      R6_2.5.1            fansi_1.0.6         XML_3.99-0.16.1     farver_2.1.2        RProtoBufLib_2.10.0 magrittr_2.0.3      scales_1.3.0        matrixStats_1.3.0   BiocGenerics_0.44.0
[41] colorspace_2.1-0    labeling_0.4.3      utf8_1.2.4          munsell_0.5.1 

恳请提供技术帮助。


内容的提问来源于stack exchange,提问作者Homap

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.06.22 22:10:03