Description Usage Arguments Value Examples
fits either a simple random walk or a correlated random walk (a random walk on velocity) in continuous time to filter Argos KF and/or LS data and predict locations at user-specified time intervals (regular or irregular)
1 2 3 4 |
d |
a data frame of observations including Argos KF error ellipse info |
vmax |
max travel rate (m/s) passed to argosfilter::sdafilter to define outlier locations |
ang |
angles of outlier location "spikes" - see ?argosfilter::sdafilter for details |
distlim |
lengths of outlier location "spikes" - see ?argosfilter::sdafilter for details |
spdf |
(logical) turn argosfilter::sdafilter on (default; TRUE) or off |
min.dt |
minimum allowable time difference between observations; dt <= min.dt will be ignored by the SSM |
pf |
just pre-filter the data, do not fit the ctrw (default is FALSE) |
model |
fit either a simple random walk ("rw") or correlated random walk ("crw") as a continuous-time process model |
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; 0 for complete silence; 1 for progress bar only; 2 for minimizer trace but not progress bar |
inner.control |
list of control settings for the inner optimization (see ?TMB::MakeADFUN for additional details) |
a list with components
|
the matched call |
|
an sf tbl of predicted location states |
|
an sf tbl of fitted locations |
|
model parameter summmary |
|
an augmented sf tbl of the input data |
|
a list of initial values |
|
the process model fit, either "rw" or "crw" |
|
time time.step in h used |
|
the object returned by the optimizer |
|
the TMB object |
|
TMB sdreport |
|
the calculated Akaike Information Criterion |
|
the processing time for sfilter |
1 2 3 4 5 6 7 8 9 10 11 12 | ## fit crw model to multiple individuals with Argos LS data
data(ellie)
fit <- fit_ssm(ellie, model = "rw", time.step = 24)
plot(fit$ssm[[1]])
data(rope)
fls <- fit_ssm(rope, model = "crw", time.step = 12)
## simple diagnostic plot for individual 3,
## showing predicted value time-series
plot(fls$ssm[[3]], what = "predicted")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.