A parametric bootstrap is used to generate a null-distribution for the likelihood ratio test-statistic to assess significance
lrtCapwire(ecm, tirm, bootstraps = 100)
fitEcm
fitTirm
Note that the likelihood ratio test should not be performed on an object inherited from fitTirmPartition
as
the partitioning algorithm assumes that there is heterogeneity in capture rates among individuals and that the rates
can be divided into classes
In most applications of likelihood ratio tests, the more parameterized model will always have a higher likelihood.
However, this is not necessarily the case for the models implemented in capwire
.
The likelihood involves a combinatorial term which denotes the number of ways a population
could give rise to the observed vector of counts. As such, for some data sets (such as those for which the assumptions of the ECM model are valid),
there will be more ways to obtain the observed data if the population is not subdivided into classes.
Pennell M.W., C.R. Stansbury, L.P. Waits and C.R. Miller. submitted. capwire: A R Package for Estimating Population Census Size from Non-Invasive Genetic Sampling
Stansbury et al. in prep
fitEcm
, fitTirm
, simEcm
## Simulate data under Equal Capture Model
data <- simEcm(n=20, s=60)
## Fit Equal Capture Model (ECM) to count data
ecm <- fitEcm(data, max.pop=200)
## Fit Two-Innate Rates Model (TIRM) to count data
tirm <- fitTirm(data, max.pop=200)
## Perform Likelihood Ratio Test
lrtCapwire(ecm=ecm, tirm=tirm, bootstraps=10)
Run the code above in your browser using DataLab