Learn R Programming

diveMove (version 0.7-5)

extractDive-methods: Extract Dives from "TDR" or "TDRcalibrate" Objects

Description

Extract data corresponding to a particular dive(s), referred to by number.

Usage

## S3 method for class 'TDR,numeric,numeric':
extractDive(obj, diveNo, id)
## S3 method for class 'TDRcalibrate,numeric,missing':
extractDive(obj, diveNo)

Arguments

obj
"TDR" object.
diveNo
Numeric vector or scalar with dive numbers to extract.
id
Numeric vector of dive numbers from where diveNo should be chosen.

Value

  • An object of class TDR or TDRspeed.

Examples

Run this code
data(divesTDR)
divesTDR
data(divesTDRcalibrate)
divesTDRcalibrate

diveX <- extractDive(divesTDR, 9, getDAct(divesTDRcalibrate, "dive.id"))
plotTDR(diveX, interact=FALSE)

diveX <- extractDive(divesTDRcalibrate, 5:10)
plotTDR(diveX, interact=FALSE)

Run the code above in your browser using DataLab