![]() |
# Fig.5.1.: Background map, overlain with element information
library(StatDA) data(kola.background) data(ohorizon) el=ohorizon[,"Mg"] X=ohorizon[,"XCOO"] Y=ohorizon[,"YCOO"] # true representation of x and y axis of map for plot xwid=diff(range(X))/12e4 ywid=diff(range(Y))/12e4 pdf("fig-5-1.pdf",width=2*xwid,height=2*ywid) par(mfrow=c(2,2),mar=c(1.5,1.5,1.5,1.5)) # Read map: m=read.pnm("backgroundmap.pnm") plot(m[1:500,1:494]) # generate plot with packground plot(X,Y,frame.plot=FALSE,xaxt="n",yaxt="n",xlab="",ylab="",type="n") plotbg(map.col=c("gray","gray","gray","gray"),add.plot=T) # scalebar scalebar(761309,7373050,861309,7363050,shifttext=-0.5,shiftkm=4e4,sizetext=0.8) # North arrow Northarrow(362602,7818750,362602,7878750,362602,7838750,Alength=0.15,Aangle=15,Alwd=1.3,Tcex=1.6) ### NEW MAP: plot(m[1:500,1:494]) bubbleFIN(X/1100-300,Y/1100-6690,el,radi=8,S=9,s=2,plottitle="",legendtitle="Mg [mg/kg]", text.cex=0.63,leg=F,ndigits=1) # Percentile legend text(min(X)+diff(range(X))*5/8,max(Y),"Growing dots:",cex=0.63) text(min(X)+diff(range(X))*5/8,max(Y)-diff(range(Y))/25,"Finnish method",cex=0.63) ### NEW MAP: # generate plot with packground plot(X,Y,frame.plot=FALSE,xaxt="n",yaxt="n",xlab="",ylab="",type="n") plotbg(map.col=c("gray","gray","gray","gray"),add.plot=T) bubbleFIN(X,Y,el,S=9,s=2,plottitle="",legendtitle="Mg [mg/kg]", text.cex=0.63,legtitle.cex=0.80) # Percentile legend ##text(min(X)+diff(range(X))*5/8,max(Y),"Growing dots:",cex=0.63) ##text(min(X)+diff(range(X))*5/8,max(Y)-diff(range(Y))/25,"Finnish method",cex=0.63) # scalebar scalebar(761309,7373050,861309,7363050,shifttext=-0.5,shiftkm=4e4,sizetext=0.8) # North arrow Northarrow(362602,7818750,362602,7878750,362602,7838750,Alength=0.15,Aangle=15,Alwd=1.3,Tcex=1.6) dev.off() |