argos2tmb: ARGOS data pre-processing

Description Usage Arguments Details Value

Description

Format ARGOS track data for filtering

Usage

1
argos2tmb(d, tstep = 1, soth = TRUE, extrap = FALSE, amf = amfCRAWL())

Arguments

d

a data frame of observations (see details)

tstep

the time step to predict to (in days)

extrap

if TRUE, the final predicted state occurs immediately before the last observation, otherwise the final predicted state occurs immediately after the last observation.

amf

Argos error scale mmultiplication factors

Details

This is an internal function used by fit_ssm to format track data for the TMB filter.

The input track is given as a data.frame where each row is an observed location and columns

'date'

observation time (POSIXct,GMT),

'lon'

observed longitude,

'lat'

observed latitude,

'lc'

ARGOS location class.

From this it calculates interpolation indices idx and weights ws such that if x is the matrix of predicted states, the fitted locations are ws*x[idx+1,] + (1-ws)*x[idx+2,].

By default the function uses the same ARGOS multiplication factors to scale location accuracy by location class as used in crawl.

Value

A list with components

y

a 2 column matrix of the lon,lat observations

K

a 2 column matrix of the ARGOS scale factors

idx

a vector of interpolation indices

ws

a vector of interpolation weights

ts

the times at which states are predicted (POSIXct,GMT)

dt

the time step at which states are predicted (secs)


ianjonsen/ssmTMB documentation built on July 5, 2019, 3:03 p.m.