Rohit Sarewar
Rohit Sarewar

Reputation: 157

ggsave throws an error

library(ggplot2)

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

> ggsave("try.jpg")

It throws an error

"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 

Can I set this cairo to TRUE ?

Upvotes: 1

Views: 632

Answers (1)

annndrey
annndrey

Reputation: 1788

I think R is trying to tell you that yous system does not have required fonts. Try to reinstall xorg-x11-fonts for 75 and 100 dpi.

Upvotes: 1

Related Questions