Created
July 29, 2016 18:15
-
-
Save rBatt/006267e3e07651d819a1e15ff6eb134b to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# dev.new(width=3.5, height=3.5) | |
png("~/Desktop/test2.png", width=3.5, height=3.5, res=150, units='in') | |
par(mfrow=c(2,1), mar=c(2.5,2.5,0.25,2.5), ps=8, cex=1, mgp=c(1,0.25,0), tcl=-0.15) | |
plot(1:10, xlab="x", ylab="y", type='o') | |
par(new=TRUE) | |
plot(x=1:10, y=cumsum(rnorm(10)), xlab="", ylab="", type='o', col='red', xaxt="n", yaxt="n") | |
axis(side=4) | |
mtext("y2", side=4, line=1) | |
plot(1:10, cumsum(rlnorm(10)), col='blue', type='o', xlab='x', ylab="y3") | |
dev.off() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment