sfilter: fit the state-space model to 'prefilter'-ed data

Description Usage Arguments Details Examples

Description

generates initial values for model parameters and unobserved states; structures data and initial values for C++ TMB template; fits state-space model; minimises the joint log-likelihood via the selected optimizer (nlminb or optim); structures and passes output object to fit_ssm

Usage

1
2
3
sfilter(x, model = c("rw", "crw"), time.step = 6, parameters = NULL,
  fit.to.subset = TRUE, optim = c("nlminb", "optim"),
  verbose = FALSE, inner.control = NULL)

Arguments

x

Argos data passed through prefilter()

model

specify which SSM is to be fit: "rw" or "crw"

time.step

the regular time interval, in hours, to predict to. Alternatively, a vector of prediction times, possibly not regular, must be specified as a data.frame with id and POSIXt dates.

parameters

a list of initial values for all model parameters and unobserved states, default is to let sfilter specifiy these. Only play with this if you know what you are doing...

fit.to.subset

fit the SSM to the data subset determined by prefilter (default is TRUE)

optim

numerical optimizer to be used ("nlminb" or "optim")

verbose

report progress during minimization

inner.control

list of control settings for the inner optimization (see ?TMB::MakeADFUN for additional details)

Details

called by fit_ssm. sfilter can only fit to an individual track, use fit_ssm to fit to multiple tracks (see ?fit_ssm).

Examples

1
2
3
data(ellie)
pf <- prefilter(ellie, vmax=10, ang=c(15,25), min.dt=120)
out <- sfilter(pf, model="rw", time.step=24)

bmcclintock/crwHMM documentation built on May 7, 2019, 12:51 a.m.