# Load example sparrow data (line transect survey type)
data(sparrowDf)
# Fit half-normal detection function
dfunc <- sparrowDf |> dfuncEstim(formula=dist ~ 1 + offset(groupsize))
# Estimate abundance given the detection function
fit <- abundEstim(dfunc
, area = units::set_units(4105, "km^2")
, ci=NULL)
summary(fit) # No confidence intervals
if (FALSE) {
# With bootstrap confidence intervals
# Requires ~3 min to complete
fit <- abundEstim(dfunc
, area = units::set_units(4105, "km^2")
, ci=0.95)
summary(fit)
}
Run the code above in your browser using DataLab