r - 如何使用 compare_mean() 函数?
问题描述
我需要使用 compare_mean() 和 stat_compare_means() 函数。这些是我正在使用的库
library(ggplot2)
library(magrittr)
library(ggpubr)
data("ToothGrowth)
当我尝试使用 compare_means 时出现此错误: compare_means(len ~ supp, data = ToothGrowth)
Error in filter_impl(.data, quo) :
Evaluation error: `as_dictionary()` is defunct as of rlang 0.3.0.
Please use `as_data_pronoun()` instead.
不确定问题是否取决于我使用 rlang_0.3.4 的事实。
我四处寻找可能的解决方案,但没有运气!
sessionInfo()
R version 3.3.3 (2017-03-06)
Platform: x86_64-apple-darwin13.4.0 (64-bit)
Running under: macOS 10.14.6
locale:
[1] C
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] dplyr_0.7.2 bindrcpp_0.2 ggpubr_0.2 magrittr_1.5 ggplot2_3.1.1
loaded via a namespace (and not attached):
[1] Rcpp_1.0.3 tidyr_0.6.3 withr_2.1.2 assertthat_0.2.0 grid_3.3.3 plyr_1.8.4
[7] R6_2.2.2 gtable_0.2.0 scales_1.0.0 rlang_0.3.4 lazyeval_0.2.0 tools_3.3.3
[13] glue_1.3.1 munsell_0.5.0 pkgconfig_2.0.1 colorspace_1.3-2 bindr_0.1 tibble_1.3.3
在此先感谢您的帮助。
解决方案
我通过将 R 版本更新到 R 3.6.3 来解决我的问题。
推荐阅读
- powershell - 运行命令而不在历史中留下痕迹
- r - 如何使用 tidyverse 语法将列名从数据框中传递到函数中?
- java - 使用 logback & hibernate 将 SQL 记录到文件中
- angular - 为什么当我在 valueChanges/statusChanges 中运行 setErrors 或 updateValueAndValidity 时,Angular 会将表单值重置为空对象?
- oracle - 使用 SQL 开发人员将数据从 CSV 文件导入 Oracle 表正在终止连接
- sas - 根据sas中的其他列添加新列
- php - CSS中的PHP变量:未定义的变量
- nginx - flask oidc auth 回调重定向到 http 而不是 https
- javascript - Fullcalendar 3 - 在 Select 函数上获取当前实例
- serverless-framework - 在无服务器框架中,有没有办法在 lambda 运行时更新由 ssm 变量填充的环境变量?