Rationale
Planning needed to assure that data collection meets goals (precision, ability to detect differences, etc.)
Simulation allows us to create "data" under hypothetical designs, compare these, and select the one(s) that achieve our goals while staying within time/ budget/ other constraints
Need
Provisional estimates of key model parameters (D, g0, sigma)
One or more potential designs for placement of detectors and replication
Built in procedure in secr
Murray Efford has written a simulation function in secr that will allow users to simulate SCR data under assumed parameter values (often, taken from a pilot study) and specified grid dimensions (shape, number / spacing of detectors). The simulated data are then used as inputs into a secr model to obtain estimates of density and precision (se density). In this script I use the secr functions make.grid() and sim.capthist() to construct detector grids for the possum example (original grid configuration and an alternative with more detectors but wider spacing). I then simulated data under each scenario using as inputs for D, sigma, and g0 estimates from the original possum data example. The simulations (which of course need to be replicated many times) suggest that the alternative design is superior, reducing CV from about 0.09 to 0.06. However, this increase in precision may or may not be justified, given the great increase in time and other resources involved (more than 2 X the number of traps). The estimates following simulation are saved in the R objects possum.est and new.est, and can be loaded before running the estimation summaries (to avoid the need to re-run the simulations).
Handmade simulation in R (Chandler)
Richard Chandler has written R code (here, after some modifications) that displays the detection functions used in SCR modeling and simulates data in a format handy for Bayesian analysis (3-dimensional arrays of encounters, padded by "virtual" animals never but potentially detected). I'll go over this code a bit in class simply to illustrate the relative simplicity of modeling these data. An additional motivation is that our eventual Bayesian coverage of SCR will wind up essentially reverse-engineering the simulation of data!