Description Usage Arguments Details Value
Threshold Model Structures for Essie
1 2 3 |
twilight |
the observed times of twilight as POSIXct. |
rise |
logical vector indicating which twilights are sunrise. |
twilight.model |
the model for the errors in twilight times. |
alpha |
parameters of the twilight model. |
beta |
parameters of the behavioural model. |
logp0 |
function to evaluate any additional contribution to the log posterior from the twilight locations. |
x0 |
suggested starting points for twilight locations. |
fixed |
logical vector indicating which twilight locations to hold fixed. |
missing |
integer vector indicating which twilights are missing. |
dt |
time intervals for speed calculation in hours. |
zenith |
the solar zenith angle that defines twilight. |
Essie requires a model structure that describes the model being fitted. This function generates basic model structures for threshold twilight data that should provide a suitable starting point for most analyses.
The essieThresholdModel
function constructs a model structure
assuming that each twilight time is associated with a single
location.
One of several models models may be selected for the errors in twilight times. The errors in twilight time are defined as the difference in the observed and true times of twilight, with sign selected so that a positive error always corresponds to a sunrise observed after the true time of sunrise, and sunset observed before the true time of sunset. That is, a positive error corresponds to the observed light level being lower than expected.
The properties of the twilight model are determined by
alpha
, which must be a vector of parameters that are
to be applied to each twilight.
The twilight.model
argument selects the distribution of the
twilight errors
Normally distributed with mean alpha[,1]
and
standard deviation alpha[,2]
,
Log Normally distributed so the log errors have
mean alpha[,1]
and standard deviation alpha[,2]
, or
Gamma distributed with shape alpha[,1]
and
rate alpha[,2]
.
The initialization locations x0
are only required when
specifying fixed locations.
Essie assumes that the average speed of travel between successive
locations is Gamma distributed. By default, the speed of travel is
calculated based on the time intervals between the twilights (in
hours), but the intervals of time actually available for travel
can be specified directly with the dt
argument. The
parameters beta[1]
and beta[2]
specify the shape and
rate of the Gamma distribution of speeds.
Twilights can be missing because either the light record was too
noisy at that time to estimate twilight reliably, or because the
tag was at very high latitude and no twilight was observed.
Missing twilights should be replaced with an approximate time of
twilight, and the vector missing
used to indicate which
twilights are approximate and which are true. This should be a
vector of integers, one for each twilight where the integer codes
signify
The twilight is not missing.
The twilight is missing, but a twilight did occur.
The twilight is missing because twilight did not occur.
The twilight is missing and it is not known if a twilight occurred.
a list with components
|
function to evaluate the contributions to the log posterior from the k-th twilight |
|
function to evaluate contribution to the log posterior from the behavioural model for the k-th track segment. |
|
a logical vector indicating which locations should remain fixed. |
|
an array of initial twilight locations. |
|
the twilight times. |
|
the sunrise indicators. |
|
the twilight model parameters. |
|
the behavioural model parameters. |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.