Skip to contents

A generalized linear model on an observed count (or continuous) response directly, with no detection sub-model and no latent abundance to marginalize. The abundance analogue of jsdm(): where abun() fits Royle's N-mixture (latent N plus imperfect detection), count() fits the observed response as a plain GLMM. This is the "relative abundance" model of spAbundance (abund): one value per site, log-link Poisson / negative-binomial counts or an identity-link Gaussian response.

Usage

count(response = c("poisson", "negbin", "gaussian", "binomial"))

Arguments

response

The response distribution: "poisson" (log link), "negbin" (negative binomial, log link, an estimated size / dispersion), "gaussian" (identity link, an estimated residual variance), or "binomial" (logit link, k successes out of n trials per site). The binomial response is the detection-free binomial GLMM of spOccupancy (svcPGBinom): supply the per-site trial count as trials = on tobs() (default 1, i.e. a Bernoulli response). Unlike the count / Gaussian areal fit, a binomial areal field is identified (the variance is pinned by n), so an icar() / car_proper() term composes with any trials.

Value

A tobs_family object.

Details

The response is a numeric vector (one value per site), supplied via y = or on a two-sided formula left-hand side (count.value ~ predictors).

See also

abun() (N-mixture: latent abundance + detection), jsdm() (occurrence GLMM, no detection).

Examples

f <- count("poisson")
f