Title: | Wildlife Sightability Modeling |
---|---|
Description: | Uses logistic regression to model the probability of detection as a function of covariates. This model is then used with observational survey data to estimate population size, while accounting for uncertain detection. See Steinhorst and Samuel (1989). |
Authors: | Fieberg John [aut], Schwarz Carl James [aut, cre] |
Maintainer: | Schwarz Carl James <[email protected]> |
License: | GPL-2 |
Version: | 1.5.5 |
Built: | 2024-11-13 03:59:50 UTC |
Source: | https://github.com/jfieberg/sightabilitymodel |
Uses logistic regression to model the probability of detection as a function of covariates. This model is then used with observational survey data to estimate population size, while accounting for uncertain detection. See Steinhorst and Samuel (1989).
John Fieberg
Maintainer: John Fieberg <[email protected]>, Carl James Schwarz <[email protected]>
Fieberg, J. 2012. Estimating Population Abundance Using Sightability Models: R SightabilityModel Package. Journal of Statistical Software, 51(9), 1-20. URL https://doi.org/10.18637/jss.v051.i09
Steinhorst, Kirk R. and Samuel, Michael D. 1989. Sightability Adjustment Methods for Aerial Surveys of Wildlife Populations. Biometrics 45:415–425.
Check the sightability model arguments for consistency
check.sightability.model.args(data, sight.model, sight.beta, sight.beta.cov)
check.sightability.model.args(data, sight.model, sight.beta, sight.beta.cov)
data |
Data.frame containing covariates for sightability model |
sight.model |
Formula with sightability model |
sight.beta |
Parameter estimates (from fitted sightability model |
sight.beta.cov |
Estimated variance-covariance matrix for parameter estimates from fitted sightability model. |
Error condition or invisible
Schwarz, C. J. [email protected].
sightability.table <- data.frame(VegCoverClass=1:5) sight.beta <- c(4.2138, -1.5847) sight.beta.cov <- matrix(c(0.7821634, -0.2820000,-0.2820000, 0.1114892), nrow=2) check.sightability.model.args( sightability.table, ~VegCoverClass, sight.beta, sight.beta.cov) ## Not run: check.sightability.model.args( sightability.table, ~VegCoverClass2, sight.beta, sight.beta.cov) check.sightability.model.args( sightability.table, ~VegCoverClass, sight.beta[1], sight.beta.cov) ## End(Not run)
sightability.table <- data.frame(VegCoverClass=1:5) sight.beta <- c(4.2138, -1.5847) sight.beta.cov <- matrix(c(0.7821634, -0.2820000,-0.2820000, 0.1114892), nrow=2) check.sightability.model.args( sightability.table, ~VegCoverClass, sight.beta, sight.beta.cov) ## Not run: check.sightability.model.args( sightability.table, ~VegCoverClass2, sight.beta, sight.beta.cov) check.sightability.model.args( sightability.table, ~VegCoverClass, sight.beta[1], sight.beta.cov) ## End(Not run)
Compute the detection probability given a sightability model
compute.detect.prob( data, sight.model, sight.beta, sight.beta.cov, check.args = FALSE )
compute.detect.prob( data, sight.model, sight.beta, sight.beta.cov, check.args = FALSE )
data |
Data.frame containing covariates for sightability model |
sight.model |
Formula with sightability model |
sight.beta |
Parameter estimates (from fitted sightability model |
sight.beta.cov |
Estimated variance-covariance matrix for parameter estimates from fitted sightability model. |
check.args |
Should the sightability model arguments be checked for consistency/ |
Vector of detection probabilities
Schwarz, C. J. [email protected].
sightability.table <- data.frame(VegCoverClass=1:5) sight.beta <- c(4.2138, -1.5847) sight.beta.cov <- matrix(c(0.7821634, -0.2820000,-0.2820000, 0.1114892), nrow=2) sightability.table$detect.prob <- compute.detect.prob( sightability.table, ~VegCoverClass, sight.beta, sight.beta.cov) sightability.table$SCF <- compute.SCF ( sightability.table, ~VegCoverClass, sight.beta, sight.beta.cov) sightability.table #"Note that the SCF != 1/detect.prob because of correction terms for covariance of beta.terms"
sightability.table <- data.frame(VegCoverClass=1:5) sight.beta <- c(4.2138, -1.5847) sight.beta.cov <- matrix(c(0.7821634, -0.2820000,-0.2820000, 0.1114892), nrow=2) sightability.table$detect.prob <- compute.detect.prob( sightability.table, ~VegCoverClass, sight.beta, sight.beta.cov) sightability.table$SCF <- compute.SCF ( sightability.table, ~VegCoverClass, sight.beta, sight.beta.cov) sightability.table #"Note that the SCF != 1/detect.prob because of correction terms for covariance of beta.terms"
Compute the sightability correction factor given a sightability and covariates
compute.SCF( data, sight.model, sight.beta, sight.beta.cov, check.args = FALSE, adjust = TRUE )
compute.SCF( data, sight.model, sight.beta, sight.beta.cov, check.args = FALSE, adjust = TRUE )
data |
Data.frame containing covariates for sightability model |
sight.model |
Formula with sightability model |
sight.beta |
Parameter estimates (from fitted sightability model |
sight.beta.cov |
Estimated variance-covariance matrix for parameter estimates from fitted sightability model. |
check.args |
Should the sightability model arguments be checked for consistency/ |
adjust |
Should the sightability value be adjusted for the sight.beta.cov. |
Vector of sightability factors (SCF)
Schwarz, C. J. [email protected].
sightability.table <- data.frame(VegCoverClass=1:5) sight.beta <- c(4.2138, -1.5847) sight.beta.cov <- matrix(c(0.7821634, -0.2820000,-0.2820000, 0.1114892), nrow=2) sightability.table$detect.prob <- compute.detect.prob( sightability.table, ~VegCoverClass, sight.beta, sight.beta.cov) sightability.table$SCF <- compute.SCF ( sightability.table, ~VegCoverClass, sight.beta, sight.beta.cov) sightability.table #"Note that the SCF != 1/detect.prob because of correction terms for covariance of beta.terms"
sightability.table <- data.frame(VegCoverClass=1:5) sight.beta <- c(4.2138, -1.5847) sight.beta.cov <- matrix(c(0.7821634, -0.2820000,-0.2820000, 0.1114892), nrow=2) sightability.table$detect.prob <- compute.detect.prob( sightability.table, ~VegCoverClass, sight.beta, sight.beta.cov) sightability.table$SCF <- compute.SCF ( sightability.table, ~VegCoverClass, sight.beta, sight.beta.cov) sightability.table #"Note that the SCF != 1/detect.prob because of correction terms for covariance of beta.terms"
Estimates var/cov matrix of inflation factors (1/prob detection) using a non-parametric bootstrap. Called by function Sight.Est if Vm.boot = TRUE.
covtheta(total, srates, stratum, subunit, covars, betas, varbetas, nboots)
covtheta(total, srates, stratum, subunit, covars, betas, varbetas, nboots)
total |
Number of animals in each independently sighted group |
srates |
Plot sampling probability (associated with the independently observed animal groups) |
stratum |
Stratum identifiers (associated with the independently observed animal groups) |
subunit |
Plot ID (associated with the independently observed animal groups) |
covars |
Matrix of sightability covariates (associated with the independently observed animal groups) |
betas |
Logistic regression parameter estimates (from fitted sightability model) |
varbetas |
Estimated variance-covariance matrix for the logistic regression parameter estimates (from fitted sightability model) |
nboots |
Number of bootstrap resamples. |
smat |
Estimated variance-covariance matrix for the inflation factors theta = (1/probability of detection). This is an n.animal x n.animal matrix. |
John Fieberg
Experimental (test trials) data set used to estimate detection probabilities for moose in MN
A data frame with 124 observations on the following 4 variables.
year of the experimental survey (test trial)
Boolean variable (=1 if moose was observed and 0 otherwise)
measurement of visual obstruction
group size (number of observed moose in each independently sighted group)
Giudice, J H. and Fieberg, J. and Lenarz, M. S. 2012. Spending Degrees of Freedom in a Poor Economy: A Case Study of Building a Sightability Model for Moose in Northeastern Minnesota. Journal of Wildlife Management 76(1):75-87.
data(exp.m) exp.m[1:5,]
data(exp.m) exp.m[1:5,]
Model averaged regression parameters and unconditional variance-covariance matrix for mountain goat sightability model (Rice et al. 2009)
The format is: beta.g = list of regression parameters (intercept and parameters associated with GroupSize, Terrain, and X.VegCover) varbeta.g = variance-covariance matrix (associated with beta.g)
Rice C.G., Jenkins K.J., Chang W.Y. (2009). A Sightability Model for Mountain Goats. The Journal of Wildlife Management, 73(3), 468-478.
data(g.fit)
data(g.fit)
Mountain Goat Survey Data from Olympic National park collected in 2004
A data frame with 113 observations on the following 9 variables.
number of animals observed in each independently sighted group [cluster size]
measure of terrain obstruction
measure of vegetative obstruction
stratum identifier
number of animals observed in each independently sighted group [same as GroupSize]
a numeric vector, Plot ID
Patti Happe ([email protected])
Jenkins, K. J., Happe, P.J., Beirne, K.F, Hoffman, R.A., Griffin, P.C., Baccus, W. T., and J. Fieberg. In press. Recent population trends in mountain goats in the Olympic mountains. Northwest Science.
data(gdat)
data(gdat)
A stratified random sample of blocks in a survey area is conducted. In each block, groups of moose are observed (usually through an aerial survey). For each group of moose, the number of moose is recorded along with attributes such as sex or age. MoosePopR() assumes that sightability is 100%. Use the SightabilityPopR() function to adjust for sightability < 100%.
MoosePopR( survey.data, survey.block.area, stratum.data, density = NULL, abundance = NULL, numerator = NULL, denominator = NULL, block.id.var = "Block.ID", block.area.var = "Block.Area", stratum.var = "Stratum", stratum.blocks.var = "Stratum.Blocks", stratum.area.var = "Stratum.Area", conf.level = 0.9, survey.lonely.psu = "fail" )
MoosePopR( survey.data, survey.block.area, stratum.data, density = NULL, abundance = NULL, numerator = NULL, denominator = NULL, block.id.var = "Block.ID", block.area.var = "Block.Area", stratum.var = "Stratum", stratum.blocks.var = "Stratum.Blocks", stratum.area.var = "Stratum.Area", conf.level = 0.9, survey.lonely.psu = "fail" )
survey.data |
A data frame containing counts of moose in each group along with a variable identifying the stratum (see stratum.var) and block (see block.id.var) |
survey.block.area |
A data frame containing for each block, the block id (see block.id.var), the area of the block (see block.area.var). The data frame can contain information for other blocks that were not surveyed (e.g. for the entire population of blocks) and information from these additional blocks will be ignored. |
stratum.data |
A data frame containing for each stratum, the stratum id (see stratum.var), the total number of blocks in the stratum (see stratum.blocks.var) and the total area of the stratum (see stratum.area.var) |
density , abundance , numerator , denominator
|
Right-handed formula identifying the variable(s) in the survey.data data frame for which the density, abundance, or ratio (numerator/denominator) are to be estimated. |
block.id.var |
Name of the variable in the data frames that identifies the block.id (the sampling unit) |
block.area.var |
Name of the variable in data frames that contains the area of the blocks (area of sampling unit) |
stratum.var |
Name of the variable in the data frames that identifies the classical stratum |
stratum.blocks.var |
Name of the variable in the stratum.data data frame that contains the total number of blocks in the stratum. |
stratum.area.var |
Name of the variable in the stratum.data data.frame that contains the total stratum area. |
conf.level |
Confidence level used to create confidence intervals. |
survey.lonely.psu |
How to deal with lonely PSU within strata. See |
A data frame containing for each stratum and for all strata (identified as stratum id .OVERALL
), the density,
or abundance or ratio estimate along with its estimated standard error and large-sample normal-based confidence interval.
Schwarz, C. J. [email protected].
To Be Added.
##---- See the vignettes for examples on how to run this analysis.
##---- See the vignettes for examples on how to run this analysis.
This function allows for classical or domain stratification when using MoosePopR(). Caution **SE are NOT adjusted for measurements on multiple domains on the same sampling unit. Bootstrapping may be required**. Consult the vignette for more details.
MoosePopR_DomStrat() assumes that sightability is 100%. Use the SightabilityPopR_DomStrat() function to adjust for sightability < 100%.
MoosePopR_DomStrat( stratum.data, selected.unit.data, waypoint.data, density = NULL, abundance = NULL, numerator = NULL, denominator = NULL, stratum.var = "Stratum", domain.var = "Domain", stratum.total.blocks.var = "Total.Blocks", stratum.total.area.var = "Total.Area", block.id.var = "Block.ID", block.area.var = "Block.Area", conf.level = 0.9, survey.lonely.psu = "fail" )
MoosePopR_DomStrat( stratum.data, selected.unit.data, waypoint.data, density = NULL, abundance = NULL, numerator = NULL, denominator = NULL, stratum.var = "Stratum", domain.var = "Domain", stratum.total.blocks.var = "Total.Blocks", stratum.total.area.var = "Total.Area", block.id.var = "Block.ID", block.area.var = "Block.Area", conf.level = 0.9, survey.lonely.psu = "fail" )
stratum.data |
A data frame containing for each combination of stratum and domain, the stratum id (see stratum.var), the domain id (see domain.var), the total number of blocks in the stratum (see stratum.total.blocks.var) and the total area of the stratum (see stratum.total.area.var) |
selected.unit.data |
A data frame containing information on the selected survey units. Required variables are the stratum (see stratum.var), domain (see domain.var), block.id (see block.id.var), and the area of the block (see block.area.var). |
waypoint.data |
A data frame containing counts of moose in each group along with a variable identifying the stratum (see stratum.var), domain (see domain.var) and block (see block.id.var). Additional variables can be included such as covariates for the sightability function (not currently used in MoosePopR) |
density , abundance , numerator , denominator
|
Right-handed formula identifying the variable(s) in the waypoint data frame for which the density, abundance, or ratio (numerator/denominator) are to be estimated. |
stratum.var |
Name of the variable in the data frames that identifies the classical stratum |
domain.var |
Name of the variable in the data frames that identifies the domain. |
stratum.total.blocks.var |
Name of the variable in the stratum.data data frame that contains the total number of blocks in the stratum. |
stratum.total.area.var |
Name of the variable in the stratum.data data.frame that contains the total stratum area. |
block.id.var |
Name of the variable in the data frames that identifies the block.id (the sampling unit) |
block.area.var |
Name of the variable in data frames that contains the area of the blocks (area of sampling unit) |
conf.level |
Confidence level used to create confidence intervals. |
survey.lonely.psu |
How to deal with lonely PSU within strata. See |
A data frame containing for each stratum and for all combinations of strata and domains
(identified as stratum id .OVERALL
), the density,
or abundance or ratio estimate along with its estimated standard error and large-sample normal-based confidence interval.
Schwarz, C. J. [email protected].
To Be Added.
##---- See the vignettes for examples on how to run this analysis.
##---- See the vignettes for examples on how to run this analysis.
This function takes the data from a classical/domain stratification and generates a bootstrap replicate suitable for analysis using MoosePopR_DomStrat(). A sightability model is allowed which "adjusts" the input data for sightability. This can also be used for SightabilityPopR() models by forcing block areas to 1 and the total block area in stratum to the number of blocks to mimic a mean-per-unit estimator. See the vignette for examples of usage.
MoosePopR_DomStrat_bootrep( stratum.data, selected.unit.data, waypoint.data, density = NULL, abundance = NULL, numerator = NULL, denominator = NULL, sight.model = NULL, sight.beta = NULL, sight.beta.cov = NULL, stratum.var = "Stratum", domain.var = "Domain", stratum.total.blocks.var = "Total.Blocks", stratum.total.area.var = "Total.Area", block.id.var = "Block.ID", block.area.var = "Block.Area", conf.level = 0.9, survey.lonely.psu = "fail", check.args = TRUE )
MoosePopR_DomStrat_bootrep( stratum.data, selected.unit.data, waypoint.data, density = NULL, abundance = NULL, numerator = NULL, denominator = NULL, sight.model = NULL, sight.beta = NULL, sight.beta.cov = NULL, stratum.var = "Stratum", domain.var = "Domain", stratum.total.blocks.var = "Total.Blocks", stratum.total.area.var = "Total.Area", block.id.var = "Block.ID", block.area.var = "Block.Area", conf.level = 0.9, survey.lonely.psu = "fail", check.args = TRUE )
stratum.data |
A data frame containing for each combination of stratum and domain, the stratum id (see stratum.var), the domain id (see domain.var), the total number of blocks in the stratum (see stratum.total.blocks.var) and the total area of the stratum (see stratum.total.area.var) |
selected.unit.data |
A data frame containing information on the selected survey units. Required variables are the stratum (see stratum.var), domain (see domain.var), block.id (see block.id.var), and the area of the block (see block.area.var). |
waypoint.data |
A data frame containing counts of moose in each group along with a variable identifying the stratum (see stratum.var), domain (see domain.var) and block (see block.id.var). Additional variables can be included such as covariates for the sightability function (not currently used in MoosePopR) |
density , abundance , numerator , denominator
|
Right-handed formula identifying the variable(s) in the waypoint data frame for which the density, abundance, or ratio (numerator/denominator) are to be estimated. |
sight.model |
A formula that identifies the model used
to estimate sightability. For example |
sight.beta |
The vector of estimated coefficients for the logistic regression sightability model. |
sight.beta.cov |
The covariance matrix of |
stratum.var |
Name of the variable in the data frames that identifies the classical stratum |
domain.var |
Name of the variable in the data frames that identifies the domain. |
stratum.total.blocks.var |
Name of the variable in the stratum.data data frame that contains the total number of blocks in the stratum. |
stratum.total.area.var |
Name of the variable in the stratum.data data.frame that contains the total stratum area. |
block.id.var |
Name of the variable in the data frames that identifies the block.id (the sampling unit) |
block.area.var |
Name of the variable in data frames that contains the area of the blocks (area of sampling unit) |
conf.level |
Confidence level used to create confidence intervals. |
survey.lonely.psu |
How to deal with lonely PSU within strata. See |
check.args |
Should arguments be checked. Turn off for extensive bootstrapping to save time. |
A list containing the input data (input.data
),
the bootstrap replicate (boot.data
), and a data frame (boot.res
) with the estimated density,
or abundance or ratio along with its estimated standard error and large-sample normal-based confidence interval.
The density/abundance/ratio over all strata is also given on the last line of the data.frame.
Schwarz, C. J. [email protected].
To Be Added.
##---- See the vignettes for examples on how to use this function
##---- See the vignettes for examples on how to use this function
Operational survey data for moose in MN (during years 2004-2007). Each record corresponds to an independently sighted group of moose, with variables that capture individual covariates (used in the detection model) as well as plot-level information (stratum identifier, sampling probability, etc).
A data frame with 805 observations on the following 11 variables.
year of survey
stratum identifier
sample plot ID
number of moose observed
number of cows observed
number of calves observed
number of bulls observed
number of unclassified animals observed (could not identify sex/age class)
measurement of visual obstruction
group size (cluster size)
Giudice, J H. and Fieberg, J. and Lenarz, M. S. 2012. Spending Degrees of Freedom in a Poor Economy: A Case Study of Building a Sightability Model for Moose in Northeastern Minnesota. Journal of Wildlife Management 76(1):75-87.
data(obs.m) obs.m[1:5, ]
data(obs.m) obs.m[1:5, ]
Prints fitted sightability model, sampling information, and sightability estimate (with confidence interval)
## S3 method for class 'sightest' print(x, ...)
## S3 method for class 'sightest' print(x, ...)
x |
Sightability object, output from call to Sight.Est() or Sight.Est.Ratio() functions. |
... |
arguments to be passed to or from other methods |
John Fieberg and Carl James Schwarz
Sight.Est
, Sight.Est.Ratio
,
summary.sightest
, summary.sightest_ratio
Data set containing sampling information from a survey of moose in MN (during years 2004-2007)
A data frame with 12 observations on the following 5 variables.
year of survey
stratum identifier
number of population units in stratum h
number of sample units in stratum h
Giudice, J H. and Fieberg, J. and Lenarz, M. S. 2012. Spending Degrees of Freedom in a Poor Economy: A Case Study of Building a Sightability Model for Moose in Northeastern Minnesota. Journal of Wildlife Management 76(1):75-87.
data(sampinfo.m) sampinfo.m
data(sampinfo.m) sampinfo.m
Estimates population abundance by 1) fitting a sightability (logistic regression) model to "test trial" data; 2) applying the fitted model to independent (operational) survey data to correct for detection rates < 1.
Sight.Est( form, sdat = NULL, odat, sampinfo, method = "Wong", logCI = TRUE, alpha = 0.05, Vm.boot = FALSE, nboot = 1000, bet = NULL, varbet = NULL )
Sight.Est( form, sdat = NULL, odat, sampinfo, method = "Wong", logCI = TRUE, alpha = 0.05, Vm.boot = FALSE, nboot = 1000, bet = NULL, varbet = NULL )
form |
a symbolic description of the sightability model to be fit (e.g., "y ~ x1 + x2 + ..."), where y is a binary response variable (= 1 if the animal is seen and 0 otherwise) and x1, x2, ... are a set of predictor variables thought to influence detection |
sdat |
'sightability' data frame. Each row represents an independent sightability trial, and columns contain the response (a binary random variable = 1 if the animal was observed and 0 otherwise) and the covariates used to model detection probabilities. |
odat |
'observational survey' data frame containing the following variable names (stratum, subunit, total) along with the same covariates used to model detection probabilities (each record corresponds to an independently sighted group of animals). stratum = stratum identifier (will take on a single value for non-stratified surveys); subunit = numeric plot unit identifier; total = total number of observed animals (for each independently sighted group of animals). |
sampinfo |
data frame containing sampling information pertaining to the observational survey. Must include the following variables (stratum, nh, Nh). stratum = stratum identifier (must take on the same values as stratum variable in observational data set), nh = number of sampled units in stratum h, Nh = number of population units in stratum h; note (this dataset will contain a single record for non-stratified designs). |
method |
method for estimating variance of the abundance estimator. Should be one of ("Wong", "SS"). See details for more information. |
logCI |
Boolean variable, default (= TRUE), indicates the confidence interval should be constructed under the assumption that (tau^ - T) has a lognormal distribution, where T is the total number of animals observed (see details) |
alpha |
type I error rate for confidence interval construction |
Vm.boot |
Boolean variable, when = TRUE indicates a bootstrap should be used to estimate cov(theta[i,j],theta[i',j']), var/cov matrix of the expansion factors (1/detection prob) |
nboot |
number of bootstrap replicates to use if Vm.boot = TRUE |
bet |
regression parameters (if the sightability model is not to be fit by Sight.Est). Make sure the order is consistent with the specification in the "form" argument. |
varbet |
variance-covariance matrix for beta^ (if the sightability model is not to be fit by Sight.Est). Make sure the order is consistent with the specification in the "form" argument. |
Variance estimation methods: method = Wong implements the variance estimator from Wong (1996) and is the recommended approach. Method = SS implements the variance estimator of Steinhorst and Samuel (1989), with a modification detailed in the Appendix of Samuel et al. (1992).
Estimates of the variance may be biased low when the number of test trials used to estimate model parameters is small (see Wong 1996, Fieberg and Giudice 2008). A bootstrap can be used to aid the estimation process by specifying Vm.boot = TRUE [note: this method is experimental, and can be time intensive].
Confidence interval construction: often the sampling distribution of tau^ is skewed right. If logCI = TRUE, the confidence interval for tau^ will be constructed under an assumption that (tau^ - T) has a lognormal distribution, where T is the total number of animals seen. In this case, the upper and lower limits are constructed as follows [see Wong(1996, p. 64-67)]:
LCL = T + [(tau^-T)/C]*sqrt(1+cv^2), UCL = T+[(tau^-T)*C]*sqrt(1+cv^2), where cv^2 = var(tau^)/(tau^-T)^2 and C = exp[z[alpha/2]*sqrt(ln(1+cv^2))].
An object of class sightest
, a list that includes the
following elements:
sight.model |
the fitted sightability model |
est |
abundance estimate [tau.hat] and its estimate of uncertainty [Vartot] as well as variance components due to sampling [Varsamp], detection [VarSight], and model uncertainty [VarMod] |
The list also includes the original test trial and operational survey data, sampling information, and information needed to construct a confidence interval for the population estimate.
John Fieberg, Wildlife Biometrician, Minnesota Department of Natural Resources
Fieberg, J. 2012. Estimating Population Abundance Using Sightability Models: R SightabilityModel Package. Journal of Statistical Software, 51(9), 1-20. URL https://doi.org/10.18637/jss.v051.i09.
Fieberg, John and Giudice, John. 2008 Variance of Stratified Survey Estimators With Probability of Detection Adjustments. Journal of Wildlife Management 72:837-844.
Samuel, Michael D. and Steinhorst, R. Kirk and Garton, Edward O. and Unsworth, James W. 1992. Estimation of Wildlife Population Ratios Incorporating Survey Design and Visibility Bias. Journal of Wildlife Management 56:718-725.
Steinhorst, R. K., and M.D. Samuel. 1989. Sightability adjustment methods for aerial surveys of wildlife populations. Biometrics 45:415-425.
Wong, C. 1996. Population size estimation using the modified Horvitz-Thompson estimator with estimated sighting probabilities. Dissertation, Colorado State University, Fort Collins, USA.
# Load data frames data(obs.m) # observational survey data frame data(exp.m) # experimental survey data frame data(sampinfo.m) # information on sampling rates (contained in a data frame) # Estimate population size in 2007 only sampinfo <- sampinfo.m[sampinfo.m$year == 2007,] Sight.Est(observed ~ voc, odat = obs.m[obs.m$year == 2007,], sdat = exp.m, sampinfo, method = "Wong", logCI = TRUE, alpha = 0.05, Vm.boot = FALSE) # BELOW CODE IS SOMEWHAT TIME INTENSIVE (fits models using 2 variance estimators to 3 years of data) # Estimate population size for 2004-2007 # Compare Wong's and Steinhorst and Samuel variance estimators tau.Wong <- tau.SS <- matrix(NA,4,3) count <- 1 for(i in 2004:2007){ sampinfo <- sampinfo.m[sampinfo.m$year == i,] # Wong's variance estimator temp <- Sight.Est(observed ~ voc, odat = obs.m[obs.m$year == i,], sdat = exp.m, sampinfo, method = "Wong", logCI = TRUE, alpha = 0.05, Vm.boot = FALSE) tau.Wong[count, ] <- unlist(summary(temp)) # Steinhorst and Samuel (with Samuel et al. 1992 modification) temp <- Sight.Est(observed ~ voc, odat = obs.m[obs.m$year == i,], sdat = exp.m, sampinfo, method = "SS") tau.SS[count, ] <- unlist(summary(temp)) count<-count+1 } rownames(tau.Wong) <- rownames(tau.SS) <- 2004:2007 colnames(tau.Wong) <- colnames(tau.SS) <- c("tau.hat","LCL","UCL") (tau.Wong <- apply(tau.Wong, 1:2, FUN=function(x){as.numeric(gsub(",", "", x, fixed = TRUE))})) (tau.SS <- (tau.Wong <- apply(tau.Wong, 1:2, FUN = function(x){as.numeric(gsub(",", "", x, fixed = TRUE))}))) ## Not run: require(gplots) par(mfrow = c(1,1)) plotCI(2004:2007-.1, tau.Wong[,1], ui = tau.Wong[,3], li = tau.Wong[,2], type = "l", xlab = "", ylab = "Population estimate", xaxt = "n", xlim=c(2003.8, 2007.2)) plotCI(2004:2007+.1, tau.SS[,1], ui = tau.SS[,3], li = tau.SS[,2], type = "b", lty = 2, add = TRUE) axis(side = 1, at = 2004:2007, labels = 2004:2007) ## End(Not run)
# Load data frames data(obs.m) # observational survey data frame data(exp.m) # experimental survey data frame data(sampinfo.m) # information on sampling rates (contained in a data frame) # Estimate population size in 2007 only sampinfo <- sampinfo.m[sampinfo.m$year == 2007,] Sight.Est(observed ~ voc, odat = obs.m[obs.m$year == 2007,], sdat = exp.m, sampinfo, method = "Wong", logCI = TRUE, alpha = 0.05, Vm.boot = FALSE) # BELOW CODE IS SOMEWHAT TIME INTENSIVE (fits models using 2 variance estimators to 3 years of data) # Estimate population size for 2004-2007 # Compare Wong's and Steinhorst and Samuel variance estimators tau.Wong <- tau.SS <- matrix(NA,4,3) count <- 1 for(i in 2004:2007){ sampinfo <- sampinfo.m[sampinfo.m$year == i,] # Wong's variance estimator temp <- Sight.Est(observed ~ voc, odat = obs.m[obs.m$year == i,], sdat = exp.m, sampinfo, method = "Wong", logCI = TRUE, alpha = 0.05, Vm.boot = FALSE) tau.Wong[count, ] <- unlist(summary(temp)) # Steinhorst and Samuel (with Samuel et al. 1992 modification) temp <- Sight.Est(observed ~ voc, odat = obs.m[obs.m$year == i,], sdat = exp.m, sampinfo, method = "SS") tau.SS[count, ] <- unlist(summary(temp)) count<-count+1 } rownames(tau.Wong) <- rownames(tau.SS) <- 2004:2007 colnames(tau.Wong) <- colnames(tau.SS) <- c("tau.hat","LCL","UCL") (tau.Wong <- apply(tau.Wong, 1:2, FUN=function(x){as.numeric(gsub(",", "", x, fixed = TRUE))})) (tau.SS <- (tau.Wong <- apply(tau.Wong, 1:2, FUN = function(x){as.numeric(gsub(",", "", x, fixed = TRUE))}))) ## Not run: require(gplots) par(mfrow = c(1,1)) plotCI(2004:2007-.1, tau.Wong[,1], ui = tau.Wong[,3], li = tau.Wong[,2], type = "l", xlab = "", ylab = "Population estimate", xaxt = "n", xlim=c(2003.8, 2007.2)) plotCI(2004:2007+.1, tau.SS[,1], ui = tau.SS[,3], li = tau.SS[,2], type = "b", lty = 2, add = TRUE) axis(side = 1, at = 2004:2007, labels = 2004:2007) ## End(Not run)
Estimates population ratios by 1) fitting a sightability (logistic regression) model to "test trial" data; 2) applying the fitted model to independent (operational) survey data to correct for detection rates < 1.
Sight.Est.Ratio( form, sdat = NULL, odat, sampinfo, method = "Wong", logCI = TRUE, alpha = 0.05, Vm.boot = FALSE, nboot = 1000, bet = NULL, varbet = NULL )
Sight.Est.Ratio( form, sdat = NULL, odat, sampinfo, method = "Wong", logCI = TRUE, alpha = 0.05, Vm.boot = FALSE, nboot = 1000, bet = NULL, varbet = NULL )
form |
a symbolic description of the sightability model to be fit (e.g., "y ~ x1 + x2 + ..."), where y is a binary response variable (= 1 if the animal is seen and 0 otherwise) and x1, x2, ... are a set of predictor variables thought to influence detection |
sdat |
'sightability' data frame. Each row represents an independent sightability trial, and columns contain the response (a binary random variable = 1 if the animal was observed and 0 otherwise) and the covariates used to model detection probabilities. |
odat |
'observational survey' data frame containing the following variable names (stratum, subunit, numerator, denominator) along with the same covariates used to model detection probabilities (each record corresponds to an independently sighted group of animals). stratum = stratum identifier (will take on a single value for non-stratified surveys); subunit = numeric plot unit identifier; numerator = total number of observed animals (for each independently sighted group of animals for numerator of ratio); denominator = total number of observed animals (for each independently sighted group of animals for denominator of ratio). |
sampinfo |
data frame containing sampling information pertaining to the observational survey. Must include the following variables (stratum, nh, Nh). stratum = stratum identifier (must take on the same values as stratum variable in observational data set), nh = number of sampled units in stratum h, Nh = number of population units in stratum h; note (this dataset will contain a single record for non-stratified designs). |
method |
method for estimating variance of the abundance estimator. Should be one of ("Wong", "SS"). See details for more information. |
logCI |
Boolean variable, default (= TRUE), indicates the confidence interval should be constructed under the assumption that (tau^ - T) has a lognormal distribution, where T is the total number of animals observed (see details) |
alpha |
type I error rate for confidence interval construction |
Vm.boot |
Boolean variable, when = TRUE indicates a bootstrap should be used to estimate cov(theta[i,j],theta[i',j']), var/cov matrix of the expansion factors (1/detection prob) |
nboot |
number of bootstrap replicates to use if Vm.boot = TRUE |
bet |
regression parameters (if the sightability model is not to be fit by Sight.Est). Make sure the order is consistent with the specification in the "form" argument. |
varbet |
variance-covariance matrix for beta^ (if the sightability model is not to be fit by Sight.Est). Make sure the order is consistent with the specification in the "form" argument. |
Variance estimation methods: method = Wong implements the variance estimator from Wong (1996) and is the recommended approach. Method = SS implements the variance estimator of Steinhorst and Samuel (1989), with a modification detailed in the Appendix of Samuel et al. (1992).
Estimates of the variance may be biased low when the number of test trials used to estimate model parameters is small (see Wong 1996, Fieberg and Giudice 2008). A bootstrap can be used to aid the estimation process by specifying Vm.boot = TRUE [note: this method is experimental, and can be time intensive].
Confidence interval construction: often the sampling distribution of tau^ is skewed right. If logCI = TRUE, the confidence interval for tau^ will be constructed under an assumption that (tau^ - T) has a lognormal distribution, where T is the total number of animals seen. In this case, the upper and lower limits are constructed as follows [see Wong(1996, p. 64-67)]:
LCL = T + [(tau^-T)/C]*sqrt(1+cv^2), UCL = T+[(tau^-T)*C]*sqrt(1+cv^2), where cv^2 = var(tau^)/(tau^-T)^2 and C = exp[z[alpha/2]*sqrt(ln(1+cv^2))].
An object of class sightest_ratio
, a list that includes the
following elements:
sight.model |
the fitted sightability model |
est |
ratio estimate, ratio.hat,abundance estimate [tau.hat] and its estimate of uncertainty [Varratio] as well as variance components due to sampling [Varsamp], detection [VarSight], and model uncertainty [VarMod] |
The list also includes the estimates for the numerator and denominator total, the original test trial and operational survey data, sampling information, and information needed to construct a confidence interval for the population estimate.
Carl James Schwarz, StatMathComp Consulting by Schwarz, [email protected]
Fieberg, J. 2012. Estimating Population Abundance Using Sightability Models: R SightabilityModel Package. Journal of Statistical Software, 51(9), 1-20. URL https://doi.org/10.18637/jss.v051.i09.
Fieberg, John and Giudice, John. 2008 Variance of Stratified Survey Estimators With Probability of Detection Adjustments. Journal of Wildlife Management 72:837-844.
Samuel, Michael D. and Steinhorst, R. Kirk and Garton, Edward O. and Unsworth, James W. 1992. Estimation of Wildlife Population Ratios Incorporating Survey Design and Visibility Bias. Journal of Wildlife Management 56:718-725.
Steinhorst, R. K., and M.D. Samuel. 1989. Sightability adjustment methods for aerial surveys of wildlife populations. Biometrics 45:415-425.
Wong, C. 1996. Population size estimation using the modified Horvitz-Thompson estimator with estimated sighting probabilities. Dissertation, Colorado State University, Fort Collins, USA.
# Load data frames data(obs.m) # observational survey data frame data(exp.m) # experimental survey data frame data(sampinfo.m) # information on sampling rates (contained in a data frame) # Estimate ratio of bulls to cows in 2007 only sampinfo <- sampinfo.m[sampinfo.m$year == 2007,] obs.m$numerator <- obs.m$bulls obs.m$denominator <- obs.m$cows Sight.Est.Ratio(observed ~ voc, odat = obs.m[obs.m$year == 2007,], sdat = exp.m, sampinfo, method = "Wong", logCI = TRUE, alpha = 0.05, Vm.boot = FALSE)
# Load data frames data(obs.m) # observational survey data frame data(exp.m) # experimental survey data frame data(sampinfo.m) # information on sampling rates (contained in a data frame) # Estimate ratio of bulls to cows in 2007 only sampinfo <- sampinfo.m[sampinfo.m$year == 2007,] obs.m$numerator <- obs.m$bulls obs.m$denominator <- obs.m$cows Sight.Est.Ratio(observed ~ voc, odat = obs.m[obs.m$year == 2007,], sdat = exp.m, sampinfo, method = "Wong", logCI = TRUE, alpha = 0.05, Vm.boot = FALSE)
A stratified random sample of blocks in a survey area is conducted. In each block, groups of moose are observed (usually through an aerial survey). For each group of moose, the number of moose is recorded along with attributes such as sex or age.
The SightabilityPopR() function adjusts for sightability < 100%.
SightabilityPopR( survey.data, survey.block.area, stratum.data, density = NULL, abundance = NULL, numerator = NULL, denominator = NULL, sight.formula = observed ~ 1, sight.beta = 10, sight.beta.cov = matrix(0, nrow = 1, ncol = 1), sight.logCI = TRUE, sight.var.method = c("Wong", "SS")[1], block.id.var = "Block.ID", block.area.var = "Block.Area", stratum.var = "Stratum", stratum.blocks.var = "Stratum.Blocks", stratum.area.var = "Stratum.Area", conf.level = 0.9 )
SightabilityPopR( survey.data, survey.block.area, stratum.data, density = NULL, abundance = NULL, numerator = NULL, denominator = NULL, sight.formula = observed ~ 1, sight.beta = 10, sight.beta.cov = matrix(0, nrow = 1, ncol = 1), sight.logCI = TRUE, sight.var.method = c("Wong", "SS")[1], block.id.var = "Block.ID", block.area.var = "Block.Area", stratum.var = "Stratum", stratum.blocks.var = "Stratum.Blocks", stratum.area.var = "Stratum.Area", conf.level = 0.9 )
survey.data |
A data frame containing counts of moose in each group along with a variable identifying the stratum (see stratum.var) and block (see block.id.var) |
survey.block.area |
A data frame containing for each block, the block id (see block.id.var), the area of the block (see block.area.var). The data frame can contain information for other blocks that were not surveyed (e.g. for the entire population of blocks) and information from these additional blocks will be ignored. |
stratum.data |
A data frame containing for each stratum, the stratum id (see stratum.var), the total number of blocks in the stratum (see stratum.blocks.var) and the total area of the stratum (see stratum.area.var) |
density , abundance , numerator , denominator
|
Right-handed formula identifying the variable(s) in the survey.data data frame for which the density, abundance, or ratio (numerator/denominator) are to be estimated. |
sight.formula |
A formula that identifies the model used
to estimate sightability. For example |
sight.beta |
The vector of estimated coefficients for the logistic regression sightability model. |
sight.beta.cov |
The covariance matrix of |
sight.logCI |
Should confidence intervals for the sightability adjusted estimates be computed
using a normal-based confidence interval on |
sight.var.method |
What method should be used to estimate the variances after adjusting for sightability. |
block.id.var |
Name of the variable in the data frames that identifies the block.id (the sampling unit) |
block.area.var |
Name of the variable in data frames that contains the area of the blocks (area of sampling unit) |
stratum.var |
Name of the variable in the data frames that identifies the classical stratum |
stratum.blocks.var |
Name of the variable in the stratum.data data frame that contains the total number of blocks in the stratum. |
stratum.area.var |
Name of the variable in the stratum.data data.frame that contains the total stratum area. |
conf.level |
Confidence level used to create confidence intervals. |
A data frame containing for each stratum and for all strata (identified as stratum id .OVERALL
), the density,
or abundance or ratio estimate along with its estimated standard error and large-sample normal-based confidence interval.
Additional information on the components of variance is also reported.
Schwarz, C. J. [email protected].
To Be Added.
##---- See the vignettes for examples on how to run this analysis.
##---- See the vignettes for examples on how to run this analysis.
This function allows for classical or domain stratification when using SightabilityPopR(). Caution **SE are NOT adjusted for measurements on multiple domains on the same sampling unit. Bootstrapping may be required**. Consult the vignette for more details.
SightabilityPopR_DomStrat() adjusts for sightability < 100%.
SightabilityPopR_DomStrat( stratum.data, selected.unit.data, waypoint.data, density = NULL, abundance = NULL, numerator = NULL, denominator = NULL, sight.formula = ~1, sight.beta = 10, sight.beta.cov = matrix(0, nrow = 1, ncol = 1), sight.logCI = TRUE, sight.var.method = c("Wong", "SS")[1], stratum.var = "Stratum", domain.var = "Domain", stratum.total.blocks.var = "Total.Blocks", stratum.total.area.var = "Total.Area", block.id.var = "Block.ID", block.area.var = "Block.Area", conf.level = 0.9 )
SightabilityPopR_DomStrat( stratum.data, selected.unit.data, waypoint.data, density = NULL, abundance = NULL, numerator = NULL, denominator = NULL, sight.formula = ~1, sight.beta = 10, sight.beta.cov = matrix(0, nrow = 1, ncol = 1), sight.logCI = TRUE, sight.var.method = c("Wong", "SS")[1], stratum.var = "Stratum", domain.var = "Domain", stratum.total.blocks.var = "Total.Blocks", stratum.total.area.var = "Total.Area", block.id.var = "Block.ID", block.area.var = "Block.Area", conf.level = 0.9 )
stratum.data |
A data frame containing for each combination of stratum and domain, the stratum id (see stratum.var), the domain id (see domain.var), the total number of blocks in the stratum (see stratum.total.blocks.var) and the total area of the stratum (see stratum.total.area.var) |
selected.unit.data |
A data frame containing information on the selected survey units. Required variables are the stratum (see stratum.var), domain (see domain.var), block.id (see block.id.var), and the area of the block (see block.area.var). |
waypoint.data |
A data frame containing counts of moose in each group along with a variable identifying the stratum (see stratum.var), domain (see domain.var) and block (see block.id.var). Additional variables can be included such as covariates for the sightability function (not currently used in MoosePopR) |
density , abundance , numerator , denominator
|
Right-handed formula identifying the variable(s) in the waypoint data frame for which the density, abundance, or ratio (numerator/denominator) are to be estimated. |
sight.formula |
A formula that identifies the model used
to estimate sightability. For example |
sight.beta |
The vector of estimated coefficients for the logistic regression sightability model. |
sight.beta.cov |
The covariance matrix of |
sight.logCI |
Should confidence intervals for the sightability adjusted estimates be computed
using a normal-based confidence interval on |
sight.var.method |
What method should be used to estimate the variances after adjusting for sightability. |
stratum.var |
Name of the variable in the data frames that identifies the classical stratum |
domain.var |
Name of the variable in the data frames that identifies the domain. |
stratum.total.blocks.var |
Name of the variable in the stratum.data data frame that contains the total number of blocks in the stratum. |
stratum.total.area.var |
Name of the variable in the stratum.data data.frame that contains the total stratum area. |
block.id.var |
Name of the variable in the data frames that identifies the block.id (the sampling unit) |
block.area.var |
Name of the variable in data frames that contains the area of the blocks (area of sampling unit) |
conf.level |
Confidence level used to create confidence intervals. |
A data frame containing for each stratum and for all combinations of strata and domains
(identified as stratum id .OVERALL
), the density,
or abundance or ratio estimate along with its estimated standard error and large-sample normal-based confidence interval.
Schwarz, C. J. [email protected].
To Be Added.
##---- See the vignettes for examples on how to run this analysis.
##---- See the vignettes for examples on how to run this analysis.
Estimates population size, with variance estimated using Steinhorst and Samuel (1989) and Samuel et al.'s (1992) estimator. Usually, this function will be called by Sight.Est
SS.est( total, srates, nh, Nh, stratum, subunit, covars, beta, varbeta, smat = NULL )
SS.est( total, srates, nh, Nh, stratum, subunit, covars, beta, varbeta, smat = NULL )
total |
Number of animals in each independently sighted group |
srates |
Plot-level sampling probability |
nh |
Number of sample plots in each stratum |
Nh |
Number of population plots in each stratum |
stratum |
Stratum identifiers (associated with the independently observed animal groups) |
subunit |
Plot ID (associated with the independently observed animal groups) |
covars |
Matrix of sightability covariates (associated with the independently observed animal groups) |
beta |
Logistic regression parameter estimates (from fitted sightability model) |
varbeta |
Estimated variance-covariance matrix for the logistic regression parameter estimates (from fitted sightability model) |
smat |
Estimated variance-covariance matrix for the inflation factors (1/probability of detection). This is an n.animal x n.animal matrix, and is usually calculated within the SS.est function. Non-null values can be passed to the function (e.g., if a bootstrap is used to estimate uncertainty due to the estimated detection parameters). |
tau.hat |
Sightability estimate of population size, tau^ |
VarTot |
Estimated variance of tau^ |
VarSamp |
Estimated variance component due to sampling aerial units |
VarSight |
Estimated variance component due to sighting process (i.e., series of binomial rv for each animal group) |
VarMod |
Estimated variance component due to estimating detection probabilities using test trial data |
John Fieberg
Steinhorst, R. K., and M.D. Samuel. 1989. Sightability adjustment methods for aerial surveys of wildlife populations. Biometrics 45:415-425.
Wong, C. 1996. Population size estimation using the modified Horvitz-Thompson estimator with estimated sighting probabilities. Dissertation, Colorado State University, Fort Collins, USA.
Estimates ratio, with variance estimated using Steinhorst and Samuel (1989) and Samuel et al.'s (1992) estimator. Usually, this function will be called by Sight.Est.Ratio()
SS.est.Ratio( numerator, denominator, srates, nh, Nh, stratum, subunit, covars, beta, varbeta, smat = NULL )
SS.est.Ratio( numerator, denominator, srates, nh, Nh, stratum, subunit, covars, beta, varbeta, smat = NULL )
numerator , denominator
|
Number of animals for the numerator and denominator of the ratio in each independently sighted group |
srates |
Plot-level sampling probability |
nh |
Number of sample plots in each stratum |
Nh |
Number of population plots in each stratum |
stratum |
Stratum identifiers (associated with the independently observed animal groups) |
subunit |
Plot ID (associated with the independently observed animal groups) |
covars |
Matrix of sightability covariates (associated with the independently observed animal groups) |
beta |
Logistic regression parameter estimates (from fitted sightability model) |
varbeta |
Estimated variance-covariance matrix for the logistic regression parameter estimates (from fitted sightability model) |
smat |
Estimated variance-covariance matrix for the inflation factors (1/probability of detection). This is an n.animal x n.animal matrix, and is usually calculated within the SS.est.Ratio function. Non-null values can be passed to the function (e.g., if a bootstrap is used to estimate uncertainty due to the estimated detection parameters). |
ratio.hat |
Sightability estimate of ratio, ratio^ |
VarRatio |
Estimated variance of ratio^ |
VarSamp , VarSight , VarMod
|
Estimated variance component due to sampling, sightability and model set to NA |
Carl James Schwarz, [email protected]
Steinhorst, R. K., and M.D. Samuel. 1989. Sightability adjustment methods for aerial surveys of wildlife populations. Biometrics 45:415-425.
Wong, C. 1996. Population size estimation using the modified Horvitz-Thompson estimator with estimated sighting probabilities. Dissertation, Colorado State University, Fort Collins, USA.
Calculates confidence interval (based on asymptotic [normal or log-normal assumption])
## S3 method for class 'sightest' summary(object, ...)
## S3 method for class 'sightest' summary(object, ...)
object |
Sightability object, output from call to Sight.Est function. |
... |
arguments to be passed to or from other methods |
Nhat or Ratiohat |
Sightability population estimate |
lcl |
Lower confidence limit |
ucl |
Upper confidence limit |
John Fieberg and Carl James Schwarz
Function to estimate the variance of the difference between two population estimates formed using the same sightability model (to correct for detection).
vardiff(sight1, sight2)
vardiff(sight1, sight2)
sight1 |
Sightability model object for the first population estimate (formed by calling Sight.Est function) |
sight2 |
Sightability model object for the second population estimate (formed by calling Sight.Est function) |
Population estimates constructed using the same sightability model will NOT be independent (they will typically exhibit positive covariance). This function estimates the covariance due to using the same sightability model and subtracts it from the summed variance.
vardiff |
numeric = var(tau^[1])+var(tau^[2])-2*cov(tau^[1],tau^[2]) |
John Fieberg
# Example using moose survey data data(obs.m) # observational moose survey data data(exp.m) # experimental moose survey data data(sampinfo.m) # information on sampling rates # Estimate population size in 2006 and 2007 sampinfo <- sampinfo.m[sampinfo.m$year == 2007, ] tau.2007 <- Sight.Est(observed ~ voc, odat = obs.m[obs.m$year == 2007, ], sdat = exp.m, sampinfo.m[sampinfo.m$year == 2007, ], method = "Wong", logCI = TRUE, alpha = 0.05, Vm.boot = FALSE) tau.2006 <- Sight.Est(observed ~ voc, odat = obs.m[obs.m$year == 2006, ], sdat = exp.m, sampinfo.m[sampinfo.m$year == 2006, ], method = "Wong", logCI = TRUE, alpha = 0.05, Vm.boot = FALSE) # naive variance tau.2007$est[2]+tau.2006$est[2] # variance after subtracting positvie covariance vardiff(tau.2007, tau.2006)
# Example using moose survey data data(obs.m) # observational moose survey data data(exp.m) # experimental moose survey data data(sampinfo.m) # information on sampling rates # Estimate population size in 2006 and 2007 sampinfo <- sampinfo.m[sampinfo.m$year == 2007, ] tau.2007 <- Sight.Est(observed ~ voc, odat = obs.m[obs.m$year == 2007, ], sdat = exp.m, sampinfo.m[sampinfo.m$year == 2007, ], method = "Wong", logCI = TRUE, alpha = 0.05, Vm.boot = FALSE) tau.2006 <- Sight.Est(observed ~ voc, odat = obs.m[obs.m$year == 2006, ], sdat = exp.m, sampinfo.m[sampinfo.m$year == 2006, ], method = "Wong", logCI = TRUE, alpha = 0.05, Vm.boot = FALSE) # naive variance tau.2007$est[2]+tau.2006$est[2] # variance after subtracting positvie covariance vardiff(tau.2007, tau.2006)
Calculates the variance of the log rate of change between 2 population estimates that rely on the same sightability model.
varlog.lam(sight1, sight2)
varlog.lam(sight1, sight2)
sight1 |
Sightability model object for the first population estimate (formed by calling Sight.Est function) |
sight2 |
Sightability model object for the second population estimate (formed by calling Sight.Est function) |
This function uses the delta method to calculate an approximate variance for the log rate of change, log(tau^[t+1])-log(tau^[t]), while accounting for the positive covariance between the two estimates (as a result of using the same sightability model to correct for detection).
loglambda |
log rate of change = log(tau^[t+1]/tau^[t]) |
varloglamda |
approximate variance of loglambda |
John Fieberg
# Example using moose survey data data(obs.m) # observational moose survey data data(exp.m) # experimental moose survey data data(sampinfo.m) # information on sampling rates # Estimate population size in 2006 and 2007 sampinfo <- sampinfo.m[sampinfo.m$year==2007, ] tau.2007 <- Sight.Est(observed ~ voc, odat = obs.m[obs.m$year==2007, ], sdat = exp.m, sampinfo.m[sampinfo.m$year == 2007, ], method = "Wong", logCI = TRUE, alpha = 0.05, Vm.boot = FALSE) tau.2006 <- Sight.Est(observed ~ voc, odat = obs.m[obs.m$year==2006, ], sdat = exp.m, sampinfo.m[sampinfo.m$year == 2006, ], method = "Wong", logCI = TRUE, alpha = 0.05, Vm.boot = FALSE) # Log rate of change varlog.lam(tau.2006, tau.2007)
# Example using moose survey data data(obs.m) # observational moose survey data data(exp.m) # experimental moose survey data data(sampinfo.m) # information on sampling rates # Estimate population size in 2006 and 2007 sampinfo <- sampinfo.m[sampinfo.m$year==2007, ] tau.2007 <- Sight.Est(observed ~ voc, odat = obs.m[obs.m$year==2007, ], sdat = exp.m, sampinfo.m[sampinfo.m$year == 2007, ], method = "Wong", logCI = TRUE, alpha = 0.05, Vm.boot = FALSE) tau.2006 <- Sight.Est(observed ~ voc, odat = obs.m[obs.m$year==2006, ], sdat = exp.m, sampinfo.m[sampinfo.m$year == 2006, ], method = "Wong", logCI = TRUE, alpha = 0.05, Vm.boot = FALSE) # Log rate of change varlog.lam(tau.2006, tau.2007)
Estimates population size, with variance estimated using Wong's (1996) estimator. This function will usually be called by Sight.Est function (but see details).
Wong.est( total, srates, nh, Nh, stratum, subunit, covars, beta, varbeta, smat = NULL )
Wong.est( total, srates, nh, Nh, stratum, subunit, covars, beta, varbeta, smat = NULL )
total |
Number of animals in each independently sighted group |
srates |
Vector of plot-level sampling probabilities (same dimension as
|
nh |
Number of sample plots in each stratum |
Nh |
Number of population plots in each stratum |
stratum |
Stratum identifiers (associated with the independently observed animal groups) |
subunit |
Plot ID (associated with the independently observed animal groups) |
covars |
Matrix of sightability covariates (associated with the independently observed animal groups) |
beta |
Logistic regression parameter estimates (from fitted sightability model) |
varbeta |
Estimated variance-covariance matrix for the logistic regression parameter estimates (from fitted sightability model) |
smat |
Estimated variance-covariance matrix for the inflation factors (1/probability of detection). This is an n.animal x n.animal matrix, and is usually calculated within the Wong.est function. Non-null values can be passed to the function (e.g., if a bootstrap is used to estimate uncertainty due to the estimated detection parameters). |
This function is called by Sight.Est, but may also be called directly by the user (e.g., in cases where the original sightability [test trial] data are not available, but the parameters and var/cov matrix from the logistic regression model is available in the literature).
tau.hat |
Sightability estimate of population size, tau^ |
VarTot |
Estimated variance of tau^ |
VarSamp |
Estimated variance component due to sampling aerial units |
VarSight |
Estimated variance component due to sighting process (i.e., series of binomial rv for each animal group) |
VarMod |
Estimated variance component due to estimating detection probabilities using test trial data |
John Fieberg
Rice CG, Jenkins KJ, Chang WY (2009). Sightability Model for Mountain Goats." The Journal of Wildlife Management, 73(3), 468- 478.
Steinhorst, R. K., and M.D. Samuel. (1989). Sightability adjustment methods for aerial surveys of wildlife populations. Biometrics 45:415-425.
Wong, C. (1996). Population size estimation using the modified Horvitz-Thompson estimator with estimated sighting probabilities. Dissertation, Colorado State University, Fort Collins, USA.
Estimates population ratio, with variance estimated using Wong's (1996) estimator. This function will usually be called by Sight.Est,Ratio() function (but see details).
Wong.est.Ratio( numerator, denominator, srates, nh, Nh, stratum, subunit, covars, beta, varbeta, smat = NULL )
Wong.est.Ratio( numerator, denominator, srates, nh, Nh, stratum, subunit, covars, beta, varbeta, smat = NULL )
numerator , denominator
|
Number of animals in numerator and denominator of each independently sighted group |
srates |
Vector of plot-level sampling probabilities (same dimension as
|
nh |
Number of sample plots in each stratum |
Nh |
Number of population plots in each stratum |
stratum |
Stratum identifiers (associated with the independently observed animal groups) |
subunit |
Plot ID (associated with the independently observed animal groups) |
covars |
Matrix of sightability covariates (associated with the independently observed animal groups) |
beta |
Logistic regression parameter estimates (from fitted sightability model) |
varbeta |
Estimated variance-covariance matrix for the logistic regression parameter estimates (from fitted sightability model) |
smat |
Estimated variance-covariance matrix for the inflation factors (1/probability of detection). This is an n.animal x n.animal matrix, and is usually calculated within the Wong.est function. Non-null values can be passed to the function (e.g., if a bootstrap is used to estimate uncertainty due to the estimated detection parameters). |
This function is called by Sight.Est.Ratio, but may also be called directly by the user (e.g., in cases where the original sightability [test trial] data are not available, but the parameters and var/cov matrix from the logistic regression model is available in the literature).
ratio.hat |
Sightability estimate of ratio, ratio^ |
Vartot |
Estimated variance of ratio^ |
VarSamp , VarSight , VarMod
|
Estimated variance component due to sampling, sightability, model are set to NA |
Carl James Schwarz [email protected]
Rice CG, Jenkins KJ, Chang WY (2009). Sightability Model for Mountain Goats." The Journal of Wildlife Management, 73(3), 468- 478.
Steinhorst, R. K., and M.D. Samuel. (1989). Sightability adjustment methods for aerial surveys of wildlife populations. Biometrics 45:415-425.
Wong, C. (1996). Population size estimation using the modified Horvitz-Thompson estimator with estimated sighting probabilities. Dissertation, Colorado State University, Fort Collins, USA.