##### R-code for making Figure 3.6. This code needs to ##### read data from "example33.dat" generated by ##### the R-code "Example33.r" x <- scan("example33.dat") mr <- numeric() for(i in 1:19){ mr[i] = abs(x[i]-x[i+1]) } i <- seq(1,20) postscript("fig36.ps",width=7.2,height=3.6,horizontal=F) par(mfrow=c(1,2), mar=c(4,4,1,2)) U=95.571 C=72.38 L=49.189 plot(i[1:20],x[1:20],type="o",lty=1,pch=16,xlab="i",ylab=expression(X[i]), mgp=c(2,1,0),xlim=c(0,20), ylim=c(45,100), cex=0.8) lines(i,rep(U,length(i)),lty=2,cex=0.8) lines(i,rep(C,length(i)),lty=2,cex=0.8) lines(i,rep(L,length(i)),lty=2,cex=0.8) axis(4,at=c(L,C,U),labels=c("L","C","U"),cex=0.8,las=1) title(xlab="(a)",cex=0.9) U=28.502 C=8.72 L=0 plot(i[1:19],mr[1:19],type="o",lty=1,pch=16,xlab="i",ylab=expression(MR[i]), mgp=c(2,1,0),xlim=c(0,20), ylim=c(-1,30), cex=0.8) lines(i,rep(U,length(i)),lty=2,cex=0.8) lines(i,rep(C,length(i)),lty=2,cex=0.8) lines(i,rep(L,length(i)),lty=2,cex=0.8) axis(4,at=c(L,C,U),labels=c("L","C","U"),cex=0.8,las=1) title(xlab="(b)",cex=0.9) graphics.off()