Latent abundance N_i ~ Poisson(lambda_i), log lambda = X beta_lambda, and
per-visit detection y_ij ~ Bernoulli(1 - (1 - r_ij)^{N_i}) with per-individual
detection logit r_ij = beta_r. Detection is site-level by default; supplying
beta_r_visit draws a per-visit covariate w and makes logit r_ij = beta_r + beta_r_visit * w_ij visit-varying. Matches the royle_nichols()
family; the response is an N x J 0/1 detection-history matrix.
Usage
simulate_royle_nichols(
N = 200,
J = 5,
beta_lambda = c(0.3, 0.5),
beta_r = -0.8,
beta_r_visit = NULL,
seed = NULL
)Arguments
- N
Number of sites (default 200).
- J
Number of visits per site (default 5).
- beta_lambda
Log-abundance coefficients
c(intercept, slope_on_x).- beta_r
Per-individual detection logit (a scalar intercept).
- beta_r_visit
Optional scalar slope on a drawn per-visit detection covariate
w. When supplied, detection varies by visit and the returned list carriesvisits = list(w = )(anN x Jmatrix) fortobs(..., visits =).- seed
Random seed.