How to separate below two plots into different pages ?
command onefile is meant for this purpose but somehow the following code draws only last of the two plots.
Any thing missing here ?
library(RSVGTipsDevice)
devSVGTips("svgplot9.svg", toolTipMode=1,onefile=TRUE,
title="SVG example plot 9: line and point types")
plot(c(0,20),c(0,5), type="n", xlab="x", ylab="y",
main="Example SVG plot with different line and point types")
for (i in 0:16) {
lines(i+(0:4), (1:5), col=max(i,1), pch=i, lty=i, type="b")
text(i, 0.5, lab=as.character(i), cex=2^(abs((i-8)/4)-1))
}
devSVGTips("svgplot9.svg", toolTipMode=1, onefile=TRUE,
title="SVG example plot 10: line and point types")
plot(c(0,20),c(0,5), type="n", xlab="x", ylab="y",
main="Example SVG plot with different line and point types")
for (i in 0:16) {
lines(i+(0:4), (1:5), col=max(i,1), pch=i, lty=i, type="b")
text(i, 0.5, lab=as.character(i), cex=2^(abs((i-8)/4)-1))
}
dev.off()
You may want to try with a single call to
devSVGTips(the second one deletes the file that was being written), either withonefile=TRUE(the two plots are overlaid on a single page) oronefile=FALSE(the two plots are in the same file, but the XML code describing them is just concatenated: this may not be valid XML and/or may require further processing).