plotDiveModel,diveModel,missing-method {diveMove}R Documentation

Methods for plotting models of dive phases

Description

All methods produce a double panel plot. The top panel shows the depth against time, the cubic spline smoother, the identified descent and ascent phases (which form the basis for identifying the rest of the dive phases), while the bottom panel shows the first derivative of the smooth trace.

Usage

## S4 method for signature 'diveModel,missing'
plotDiveModel(x, diveNo)

## S4 method for signature 'TDRcalibrate,missing'
plotDiveModel(x, diveNo)

## S4 method for signature 'numeric,numeric'
plotDiveModel(
  x,
  y,
  times.s,
  depths.s,
  d.crit,
  a.crit,
  diveNo = 1,
  times.deriv,
  depths.deriv,
  d.crit.rate,
  a.crit.rate
)

Arguments

x

A diveModel (diveModel,missing method), numeric vector of time step observations (numeric,numeric method), or TDRcalibrate object (TDRcalibrate,numeric method).

diveNo

integer representing the dive number selected for plotting.

y

numeric vector with depth observations at each time step.

times.s

numeric vector with time steps used to generate the smoothing spline (i.e. the knots, see diveModel).

depths.s

numeric vector with smoothed depth (see diveModel).

d.crit

integer denoting the index where descent ends in the observed time series (see diveModel).

a.crit

integer denoting the index where ascent begins in the observed time series (see diveModel).

times.deriv

numeric vector representing the time steps where the derivative of the smoothing spline was evaluated (see diveModel).

depths.deriv

numeric vector representing the derivative of the smoothing spline evaluated at times.deriv (see diveModel).

d.crit.rate

numeric scalar: vertical rate of descent corresponding to the quantile used (see diveModel).

a.crit.rate

numeric scalar: vertical rate of ascent corresponding to the quantile used (see diveModel).

Methods (by class)

Author(s)

Sebastian P. Luque spluque@gmail.com

See Also

diveModel

Examples

## Too long for checks

## Continuing the Example from '?calibrateDepth':
utils::example("calibrateDepth", package="diveMove",
               ask=FALSE, echo=FALSE, run.donttest=TRUE)

## 'diveModel' method
dm <- getDiveModel(dcalib, 100)
plotDiveModel(dm, diveNo=100)

## 'TDRcalibrate' method
plotDiveModel(dcalib, diveNo=100)



[Package diveMove version 1.6.2 Index]