r - 从 ggstatsplot 增加 ggbetweenstats 的 inplot 均值的字体大小
问题描述
使用 ggstatsplot 时如何增加图中均值的字体大小?特别是ggbetweenstats?
我可以使用下面的代码更改所有内容的字体大小,实际图中的平均值除外。
ggplot.component = list(theme(text = element_text(size = 21))))
生成上图的代码
ggbetweenstats(
data = iris,
x = Species,
y = Sepal.Length,
title = "Distribution of sepal length across Iris species"
)
解决方案
您可以通过以下方式设置字体大小和标签样式centrality.label.args
:
library(ggstatsplot)
ggbetweenstats(
data = iris,
x = Species,
y = Sepal.Length,
title = "Distribution of sepal length across Iris species",
centrality.label.args = list(size = 8)
)
推荐阅读
- python - 我如何在scrapy(python)中连接mongodb atlas和piplines?
- java - XSSFCellStyle.BORDER_THIN - poi 4.1.2 中的(BORDER_THIN 无法解析或不是字段)
- bash - 停用时在 conda env_vars.sh 中导出/取消设置
- qt - 如何更改 ComboBox qml 中的三角形?
- r - 命令在 powershell 中工作,但不能通过 system()/system2()/shell() 工作?
- java - JavaFX - 当我创建 TextField 的新实例时,整个窗口变成白色
- android - 在服务器中管理用户位置存储的最佳方法
- react-native - 如果其他反应原生
- c++ - 在 C++ 中删除 ArrayList 中的零
- angular - 在项目中使用 npm 自定义库时面临问题