################################################################################## # MULTIPLE SCALES MAY BE PERTINENT FOR THE STUDY OF SPATIAL PATTERN ################################################################################## # define space x <- seq(1,100,0.1) # define four components of a spatial pattern y1 <- sin(x/15) y2 <- sin(x/10) y3 <- sin(x/5) y4 <- sin(x) # plot the components plot(x, y1, type="l", lwd=4) plot(x, y2, type="l", lwd=4) plot(x, y3, type="l", lwd=4) plot(x, y4, type="l", lwd=4) # create matrix with the four compoenents of the spatial pattern ev <- cbind(y1,y2,y3,y4) summary(ev) var(ev) sev<-scale(ev) summary(sev) var(sev) attributes(sev) # plot combinations of the components of the spatial pattern plot((sev[,1] + sev[,2]), type="l", lwd=5) points(sev[,1], col="red") points(sev[,2], col="blue") plot(sev[,1] + sev[,3], type="l", lwd=5) points(sev[,1], col="red") points(sev[,3], col="blue") plot(sev[,1] + sev[,4], type="l", lwd=5) points(sev[,1], col="red") points(sev[,4], col="blue") plot(sev[,2] + sev[,3], type="l", lwd=5) points(sev[,2], col="red") points(sev[,3], col="blue") plot(sev[,2] + sev[,4], type="l", lwd=5) points(sev[,2], col="red") points(sev[,4], col="blue") plot(sev[,3] + sev[,4], type="l", lwd=5) points(sev[,3], col="red") points(sev[,4], col="blue")