- Open a graphics device.
- Create the plot.
- Close the graphics device.
pdf("mygraphs/myplot.pdf",width=5,height=5)
plot(x,y)
dev.off()
Another way to plot, is first to make a plot and then save
plot(x,y)
dev.copy(pdf,"mygraphs/myplot.pdf",width=7,height=5)
dev.off()
No comments:
Post a Comment