[R] Saving .eps files with Times New Roman font

David Winsemius dwinsemius at comcast.net
Thu Jun 23 19:26:23 CEST 2016


> On Jun 23, 2016, at 10:15 AM, A A via R-help <r-help at r-project.org> wrote:
> 
> In RGui, I'm running the following bit of code:
> windowsFonts(A=windowsFont("Times New Roman"))
> plot(0,0, ylab='y axis', xlab='x axis',main='title',family="A")
> The labels and title appear in Times New Roman font. So far, so good. However, when I right click the figure and select 'Save as postscript...', I get a .eps file of the plot, but without the font formatting that I applied. Is there any way to apply the formatting so that it gets saved?

I'm now a Windows user but I expect that the windowsFonts function is setting the fonts for the interactive graphics device rather than the postscript device. You should try reviewing:

?postscriptFonts
?postscript   # if you want to control the device settings

> 
> 	[[alternative HTML version deleted]]
> 
> ______________________________________________
> R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.

David Winsemius
Alameda, CA, USA



More information about the R-help mailing list