[R] Change font type PNG device with Lattice xyplot

RBlonk robbert.blonk at gmail.com
Tue Apr 28 10:03:07 CEST 2009


Dear All,
I have some problems with changing the default font (Arial) in a xyplot
which is printed using the PNG-device. Although some things have been
mentioned about this in the forum, I still couldn't figure it out. Can
someone help me out?n Thanks in advance!

I want to print the plot for pasting in Microsoft Word
OS: Windows XP

see example:

a<-data.frame(x=c(1:5),y=c(2,2,3,3,4))
png(filename="let's change the font.png", width=480, height=300,
pointsize=12)
  xyplot(y~x,data=a,
    ylab="y-axis",
    xlab="x-axis",
    ylim=c(0,5),
    par.settings=list(axis.line=list(lwd=1.5),
    strip.border=list(lwd=2)),
    scales=list(y=list(tick.number=5,tck=0.5)),
    type="l",lwd=3,lty=1,col=2)
dev.off()

Robbert
-- 
View this message in context: http://www.nabble.com/Change-font-type-PNG-device-with-Lattice-xyplot-tp23272171p23272171.html
Sent from the R help mailing list archive at Nabble.com.




More information about the R-help mailing list