# Load example sparrow data (line transect survey type)
data(sparrowDetectionData)
data(sparrowSiteData)
# Fit half-normal detection function
dfunc <- dfuncEstim(formula=dist ~ 1 + offset(groupsize)
, detectionData=sparrowDetectionData)
# Estimate abundance given a detection function
# Note: a person should do more than R=20 bootstrap iterations
fit <- abundEstim(dfunc
, detectionData = sparrowDetectionData
, siteData = sparrowSiteData
, area = units::set_units(4105, "km^2")
, R=20
, ci=0.95)
# Print results
print(fit)
Run the code above in your browser using DataLab