source("~/programs/R/map/map.r") args(map) CTFSdata() CTFSElev_bci=ctfs.elev$bci str(CTFSElev_bci) args(maptopo) maptopo(elevmat=CTFSElev_bci$mat,plotdim=c(1000,500)) maptopo(elevmat=CTFSElev_bci$mat,plotdim=c(1000,500),plotside=8) args(maptopo) CTFSgrowth() CTFSplot('bci',6:7) CTFSplot('bci',c(4,7)) head(BCI.full7) search() options(width=120) search() options(width=80) search() ls(2) head(bci.full7) search() tail(bci.full7) args(growth) tail(bci.full7) args(growth) library(date) growth(census1=bci.full4,bci.full7) growth(census1=bci.full4,census2=bci.full7,method='I')$rate growth(census1=bci.full4,census2=bci.full7,method='E')$rate growth(census1=bci.full4,census2=bci.full7,split1=bci.full4$sp)$rate head(growth(census1=bci.full4,census2=bci.full7,split1=bci.full4$sp)$rate) half=character() half[bci.full4$gx<500]='west' half[bci.full4$g>=500]='east' (growth(census1=bci.full4,census2=bci.full7,split1=half)$rate) half[bci.full4$gx>=500]='east' (growth(census1=bci.full4,census2=bci.full7,split1=half)$rate) (growth(census1=bci.full4,census2=bci.full7,split1=half)$CI) (growth(census1=bci.full4,census2=bci.full7,split1=half)$clim) args(growth.dbh) growth.dbh(census1=bci.full4,census2=bci.full7,classbreak=c(10,50,100,300)) growth.dbh(census1=bci.full4,census2=bci.full7,classbreak=c(10,50,100,300))$rate growth.dbh(census1=bci.full4,census2=bci.full7,classbreak=c(10,50,100,300),method='E')$rate gi=growth.dbh(census1=bci.full4,census2=bci.full7,classbreak=c(10,50,100,300),method='I') is.list(gi) is.dataframe(gi) is.data.frame(gi) str(gi) gi$rate str(gi$rate) plot(gi$dbhmean,gi$rate) plot(gi$dbhmean,gi$rate,ylim=c(0,5),type='l') gi$rate gi$dbhmean gi=growth.dbh(census1=bci.full4,census2=bci.full7,classbreak=c(10,50,100,300),method='I') gi=growth.dbh(census1=bci.full4,census2=bci.full7,classbreak=c(10,20,50,100,300,1500),method='I') gi$rate plot(gi$dbhmean,gi$rate,ylim=c(0,5),type='l') gi$N gi$clim lines(gi$dbhmean,gi$clim+gi$rate) plot(gi$dbhmean,gi$rate,ylim=c(0,14),type='l') lines(gi$dbhmean,gi$clim+gi$rate,lty='dotted') lines(gi$dbhmean,gi$rate-gi$clim,lty='dotted') args(growth.eachspp) gs=growth.eachspp(bci.full4,bci.full7,classbreak=c(10,50,100,300)) head(gs$rate) gs$rate['tri2tu,] ' ] gs$rate['tri2tu',] gi$rate gi=growth.dbh(census1=bci.full4,census2=bci.full7,classbreak=c(10,50,100,300),method='I') gi$rate args(growth) gi$N gi=growth.dbh(census1=bci.full4,census2=bci.full7,classbreak=c(10,50,100,300),method='I',maxgrow=1000) gi$N gi=growth.dbh(census1=bci.full4,census2=bci.full7,classbreak=c(10,50,100,300),method='I',maxgrow=35) gi$N gi=growth.dbh(census1=bci.full4,census2=bci.full7,classbreak=c(10,50,100,300),method='I',err.limit=10000) args(growth.indiv) g=growth.indiv(bci.full4,bci.full7) dim(g) head(g) tail(g) head(subset(g,status1=='A' & status2=='A')) plot(incgr~dbh1,data=g) subset(g,incgr>35) subset(g,incgr>30) savehistory('histFrontRoyal24July2013.txt') args(map) args(maptopo) str(CTFSElev_bci) head(CTFSElev_bci$col) summary(CTFSElev_bci) summary(CTFSElev_bci$col) CTFSElev_rabi=ctfs.elev$rabi summary(CTFSElev_rabi$col) str(CTFSElev_rabi$col) args(maptopo) str(CTFSElev_rabi) str(CTFSElev_rabi$mat) CTFSElev_bci$mat[1:5,1:8] args(maptopo) maptopo(elevmat=CTFSElev_bci$mat,plotdim=c(1000,500)) maptopo(elevmat=CTFSElev_bci$mat,plotdim=c(1000,500),plotside=8) maptopo(elevmat=CTFSElev_bci$mat,plotdim=c(1000,500),plotside=8,interval=10) maptopo(elevmat=CTFSElev_bci$mat,plotdim=c(1000,500),plotside=8,interval=1) head(g) points(gy~gx,data=subset(g,incgr>20)) points(gy~gx,data=subset(g,incgr>20),col='red') points(gy~gx,data=subset(g,gx<200)) maptopo(elevmat=CTFSElev_bci$mat,plotdim=c(1000,500),plotside=8,interval=1) points(gy~gx,data=g,pch='.') maptopo(elevmat=CTFSElev_bci$mat,plotdim=c(1000,500),plotside=8,interval=1,add=TRUE,col='green') maptopo(elevmat=CTFSElev_bci$mat,plotdim=c(1000,500),plotside=8,interval=1,add=TRUE,clr='green') maptopo(elevmat=CTFSElev_bci$mat,plotdim=c(1000,500),plotside=8,interval=1,add=TRUE,clr='red') maptopo(elevmat=CTFSElev_bci$mat,plotdim=c(1000,500),plotside=8,interval=1,add=TRUE,clr='red') savehistory('histFrontRoyal24July2013.txt') savehistory('~/meetings_workshops/FrontRoyal/history/histFrontRoyal24July2013.txt') savehistory('~/meetings_workshops/Rmodeling/FrontRoyal/history/histFrontRoyal24July2013.txt')