r - ggsave 抛出错误

标签 r centos

图书馆(ggplot2)

> ggplot(mpg, aes(displ, hwy))+geom_point()

> ggsave("try.jpg")

它抛出一个错误

"Saving 6.99 x 7 in image
Error in grid.Call(L_textBounds, as.graphicsAnnot(x$label), x$x, x$y,  : 
  X11 font -adobe-helvetica-%s-%s-*-*-%d-*-*-*-*-*-*-*, face 1 at size 12 could not be loaded".
> capabilities()

    jpeg      png     tiff    tcltk      X11     aqua http/ftp  sockets 
    TRUE     TRUE    FALSE     TRUE     TRUE    FALSE     TRUE     TRUE

    libxml     fifo   cledit    iconv      NLS  profmem    cairo 
   TRUE     TRUE     TRUE     TRUE     TRUE     TRUE    FALSE 

我可以将此 cairo 设置为 TRUE 吗?

最佳答案

我认为 R 试图告诉您您的系统没有所需的字体。尝试为 75 和 100 dpi 重新安装 xorg-x11-fonts。

关于r - ggsave 抛出错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/16962250/

相关文章:

r - 限制数据帧中的小数位数 (R)

r - 动态生成引用类

使用 TwitteR 的一段时间内推文的随机样本

PHP安装\构建

linux - CentOS 7 上的 Docker 卷

php - CentOS:无法安装 PhP GD

r - 使用 ggplot 绘制 parking 场占用的 parking 位

r - 基于 R 中内存使用的触发事件

maven - VM Linux Centos 上的 Jenkins Master 和 VM Windows 7 上的 Jenkins Slave

NGINX 反向代理设置未重定向到指定目标,仍显示默认 centos 索引页面