Wiley
Browse
1/1
7 files

Supplement 1. R and WinBUGS code to facilitate running of the covariate state-space model.

dataset
posted on 2016-08-10, 08:25 authored by Sophie Bestley, Ian D. Jonsen, Mark A. Hindell, Robert G. Harcourt, Nicholas J. Gales

File List

argos.csv (MD5: 231845256e0e3e2780b89b1979b11593)

dive.csv (MD5: 0637c54ff8df8166d7f07b80295eaa5a)

example.R (MD5: )5c05f59f227390015949a4789d2feef9

dat4bugsCOV.R (MD5: e1648cc3144721f82d351922cd28f7e5)

ssmMeta.R (MD5: 63baa0688eb6061afb2f8d7a80a6d2f4)

DCRWSmeta_cov1oneway.txt (MD5: 4d1eadc5bc3c88f9d3ac1534c71ab5ba)

Description

Supplement contains sample data, functions and scripts to prepare the data and fit the covariate state-space model presented in this paper. Two raw data files contain samples of Argos location data (argos.csv) and individual dive data (dive.csv) for a subset of Southern elephant seals tagged with CTD-SRDLs at Davis Station, Antarctica in 2011 under the Australian Integrated Marine Observing System. Following the worked example given in the example.R file should enable readers to run the covariate state-space model and/or fit their own Argos and dive data using the R and WinBUGS codes provided (dat4bugsCOV.R, ssmMeta.R, and DCRWSmeta_cov1oneway.txt).

The argos.csv file is a comma-separated file containing the Southern elephant seal raw Argos tracking data.

Column definitions

  1. "id" - is a unique identifier for the seal from which the tracking data set came.
  2. "time" -  is the GMT date-time of each observation with the following format: "2001-11-13 07:59:59".
  1. "lc" is the Argos location quality class of each observation. Values in ascending order of quality are: "Z", "B", "A", "0", "1", "2", "3".
  2. "lon" is the observed longitude in decimal degrees.
  1. "lat" is the observed latitude in decimal degress.

The dive.csv file is a comma-separated file containing the Southern elephant seal individual dive data.

Column definitions

  1. "id" - is a unique identifier for the seal from which the dive dataset came (same as for the argos.csv file).
  2. "time" -  is the GMT date-time of each observation with the following format: "2001-11-13 07:59:59".
  1. "MAX_DEP" – the dive covariate used here is the logarithm of the maximum depth in meters recorded for the dive. The reader may use any dive covariate, raw or pre-processed (with any name), here.

example.R  contains R code for the worked Southern elephant seal example showing model implementation.

dat4bugsCOV.R is an R function which prepares and writes input data for WinBUGS model.

ssmMeta.R  is an R function which fits covariate state-space model to Argos tracking data.

DCRWSmeta_cov1oneway.txt  contains WinBUGS code for the covariate state-space model.

History