source("popweb.R")# Load foodweb visualisation function
popweb(lake.Ontario)# Food web structure visualization
(r<-POSrates(PCB,lake.Ontario))# Rate constants
Kin.w<-r[["Kin"]][,1]
Kout.w<-r[["Kout"]][,1]
BCF<-Kin.w/Kout.w# Bioconcentration factors
par(mfrow=c(1,3))
dotchart(Kin.w,main="Kin")
dotchart(Kout.w,main="Kout")
dotchart(BCF,main="BCF")
(A<-POSmatrices(PCB,lake.Ontario)[["A"]])
lambda<-eigen(A)$values
par(mfrow=c(2,1))
plot(lambda,xlab="",ylab="Eigenvalue (1/d)")#similar to resiliense of the system: is the system. changing fast or slow. smallest absolute value means ow resilience and long response time.
plot((-1/lambda)/365,xlab="",ylab="Response time (year)")