run.d.wave: 'd.wave' 2D lunge detector for entire record, with validation

Description Usage Arguments Value Author(s) See Also Examples

View source: R/run.d.wave.R

Description

d.wave 2D lunge detector for entire record, with validation

Usage

1
2
3
run.d.wave(name = NA, data = NULL, show.info = F, plotting = T,
  match.window = 15, smooth.window = 4, pper = 16, rper = 20,
  min.pdist = 40, min.ppow = 0.05, pk.e = 0.85)

Arguments

name

Name of animal to analyse, if data are to be read from external files (default is NA)

data

Data frame containing dive info (e.g. created using read.depth, read.lunges, join.dstamp and number.dive).

show.info

Logical, should detaild information be shown while running function

plotting

Whether to plot the results or not

match.window

Size of time window within which peaks and lunges should be considered matched

smooth.window

Initial window of smooth for gaussian running mean filter (equivalent to presmooth.window in d.wave)

pper

Peak wavelet period for weighted power analysis (equivalent to pk.per in d.wave)

rper

Range of all periods to be considered in weighted power analysis (equivalent to per.rng in d.wave)

min.pdist

Minimum period between consecutive peaks (equivalent to min.pkdist in d.wave)

min.ppow

Minimum amplitude for peak to be considered significant (equivalent to a.pk in d.wave)

pk.e

Proportion of a.pk, used to set the duration of what is considered a peak (equivalent to pk.env in d.wave)

Value

Returns a list with objects parameters, containing all parameters used when running detector, df data frame containing original data plus peak detections and matching information, detects list containing wavelet ojects for each dive, matched list containing 1) a logical vector indicating the occurrence of matched peaks/lunges, and 2) confusion matrix for matched and unmatched peaks/lunges

Author(s)

Martin Biuw

See Also

read.lunges to read lunge event timestamps, read.depth to read depth time series, join.dstamp to merge lunge events and dive data, number.dive to add dive numeric ID column, d.wave to run lunge detector omn single dives.

Other Lunge detector functions: d.wave.TDR.original, d.wave.TDR, d.wave, dstamp.plot, filter.lunges, gpsWhale, import.all.rene, join.dstamp, matDive, matLunge, match.lunges, mkDygraph, ncWhale, number.dive, optim.d.wave, read.depth, read.lunges, whale2dstamp, wt.image.plot

Examples

1
2
3
4
5
d <- read.depth(whalename='mn16_Jan25b')
t <- read.lunges(whalename='mn16_Jan25b')
df <- join.dstamp(d, t)
df$dive <- number.dive(df$depth)
df <- run.d.wave(data=df)

embiuw/dWave documentation built on April 24, 2020, 11:52 a.m.