Learn R Programming

unmarked (version 1.4.3)

unmarkedPowerList: Summarize a series of unmarked power analyses

Description

A list of power analyses created with powerAnalysis can be combined using unmarkedPowerList, allowing comparison e.g. between different study designs/sample sizes. A series of methods for unmarkedPowerList objects are available including a plot method.

Usage

# S4 method for unmarkedPower
unmarkedPowerList(object, ...)
# S4 method for unmarkedPowerList
show(object)
# S4 method for unmarkedPowerList
summary(object, showIntercepts = FALSE, ...)
# S4 method for unmarkedPowerList,ANY
plot(x, power=NULL, param=NULL, ...)

Value

A unmarkedPowerList object, a summary of the object in the console, or a summary plot, depending on the method

Arguments

object,x

For unmarkedPowerList, an unmarkedPower object. For show, summary, plot, an unmarkedPowerList object.

showIntercepts

Show intercepts output? This is rarely useful.

power

If specified, adds a dotted line to the plot at this target power value.

param

When plotting, the model parameter to plot power vs. sample size for. By default this is the first parameter.

...

For unmarkedPowerList, other unmarkedPower objects to combine into the list.

Author

Ken Kellner contact@kenkellner.com

See Also

powerAnalysis

Examples

Run this code

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