[R] Failure to produce italics in jpeg

Dennis Fisher fisher at plessthan.com
Sat Jan 23 18:21:22 CET 2010


Colleagues,

Using R 2.10.1 in OS X (Snow Leopard), I created JPEG documents that  
were intended to include italicized text.  In the JPEG versions, the  
italics appear in bold-face.  The identical code (except for the call  
to the device) yields italics in PDF.  A minimal example is:

PDF version:
> pdf("plot.pdf")
> plot(1,1)
> mtext(bquote(italic(P) < .(0.005)))
> dev.off()

JPEG version:
> jpeg(file="plot.jpeg", pointsize=12, bg="white", res=150, quality=100)
> plot(1,1)
> mtext(bquote(italic(P) < .(0.005)))
> dev.off()

I can't find any info in the help pages for either jpeg or bquote that  
explain this.

Any ideas?

Dennis

Dennis Fisher MD
P < (The "P Less Than" Company)
Phone: 1-866-PLessThan (1-866-753-7784)
Fax: 1-866-PLessThan (1-866-753-7784)
www.PLessThan.com



More information about the R-help mailing list