R eps export and import into Word 2010

后端 未结 5 487
别跟我提以往
别跟我提以往 2020-12-18 06:29

I\'m having trouble with exporting eps files from R and importing into Word 2010.

I\'m using ggplot2 plots, eg

library(ggplot2)
p <-          


        
5条回答
  •  悲&欢浪女
    2020-12-18 06:42

    I solved the problem with exporting .eps files from R and importing into Word 2010 on Windows 7 using the colormodel="rgb" option (defaults to "srgb") of the postscript command.

    postscript("RPlot.eps", height = 4, width = 4, horizontal = FALSE, 
             paper = "special", colormodel = "rgb")
    library(ggplot2)
    p <- qplot(disp,hp,data=mtcars) + stat_smooth(se=FALSE, method="loess")
    p
    dev.off()
    

提交回复
热议问题