by jhines » Fri Mar 15, 2024 11:19 am
To simulate the capture-histories for CJS model, assuming N individuals initially captured in occasion 1:
1) Generate a random number, X, between 0 and 1. Compare X to survival rate, S. If X<=S, then individual survives to occasion 2. For example, if S=0.7, approximately 70% of random numbers between 0 and 1 will be <= 0.7, so on average, 70% of individuals will survive.
2) Generate another random number, Y. Compare Y to capture probability, p. If Y<=p, then individual is captured in occasion 2, so tack ‘1’ to end of capture-history. Otherwise, tack ‘0’ to end of capture-hsitory.
3) Repeat 1 & 2 for each occasion.
4) Repeat 1-3 for N individuals initially captured in occasion 1.
This generates a single simulated dataset which can be analyzed with RMark. We would not expect the estimated survival and capture probabilities from this simulated dataset to match the input survival (S) and capture (p) probabilities exactly. However, if we repeat the process many times, the average of the estimated survival rates and capture probabilities should be very close to the input S and p parameters.
Additionally, we can evaluate the proportion of times the true S falls within the confidence interval of the estimated S, or compare the deviance from your real dataset with the distribution of deviances from all simulated datasets to get an idea of model “fit”.
Data can also be simulated for other model-types. For models with a probability of entry parameter (B), we would start by simulating each individual in the “super population” and first determine if the animal is in the local population in occasion 1 (if X <= B) then individual is in local population and can be captured in occasion 1. If not, then capture-history starts with “0” and test if animal enters between occasions 1 and 2. Once an individual is in the local population, determine if captured and survives to each occasion.
The simulation procedure can be as complicated as necessary to match whatever model is needed.