[R] Can you use two offsets in gam (mgcv)?
alice.jones at noc.soton.ac.uk
Mon Jun 17 11:17:46 CEST 2013
I have been trying to find out whether it is possible to use more than one
offset in a gam (in mgcv).
The reason I would like to do this is to 1) account for area surveyed in a
Poisson model of sightings of porpoises within defined grid cells (each cell
has a slightly different area) and 2) account for detection probability
within each grid cell (some grid cells are further away from the observer
than others, and this affects the likelihood of seeing the porpoises).
I would like to specify the model as something like:
gam(porpoises ~ s(covariates) + log(offset(grid cell area) +
log(offset(detection), family = "poisson"). Does this seems sensible? I am
unsure of the way the two offsets will work together........ are they going
to be additive? I have had a search online and looked in the Wood 2006 book,
mgcv manual etc, but haven't managed to find anything that mentions using
Any advice would be very welcome.
View this message in context: http://r.789695.n4.nabble.com/Can-you-use-two-offsets-in-gam-mgcv-tp4669684.html
Sent from the R help mailing list archive at Nabble.com.
More information about the R-help