if (FALSE) {
# Build unmarkedFrame
umf <- unmarkedFrameOccu(y = matrix(NA, 300, 8),
siteCovs = data.frame(elev=rnorm(300)))
# Run power analyses
cf <- list(state = c(0, -0.4), det = 0)
pa1 <- powerAnalysis(umf, model=occu, formula=~1~elev, effects=cf)
pa2 <- powerAnalysis(umf[1:100,], model=occu, formula=~1~elev, effects=cf)
# Combine them into a list
(pl <- unmarkedPowerList(pa1, pa2))
# Look at summary plot for elev effect
plot(pl, power=0.8, param='elev')
}
Run the code above in your browser using DataLab