Learn R Programming

banter (version 0.9.6)

numEvents: Number of Events

Description

Return the number of events in a BANTER model by species.

Usage

numEvents(x, model = "event")

Value

a data.frame giving the number of events available for each species.

Arguments

x

a banter_model object.

model

name of model to extract. Default is "event" to summarize the event-level model. Can also be name of a detector.

Author

Eric Archer eric.archer@noaa.gov

References

Rankin, S. , Archer, F. , Keating, J. L., Oswald, J. N., Oswald, M. , Curtis, A. and Barlow, J. (2017), Acoustic classification of dolphins in the California Current using whistles, echolocation clicks, and burst pulses. Marine Mammal Science 33:520-540. doi:10.1111/mms.12381

Examples

Run this code
data(train.data)
# initialize BANTER model with event data
bant.mdl <- initBanterModel(train.data$events)
# add all detector models
bant.mdl <- addBanterDetector(
  bant.mdl, train.data$detectors, 
  ntree = 50, sampsize = 1, num.cores = 1
)
# run BANTER event model
bant.mdl <- runBanterModel(bant.mdl, ntree = 1000, sampsize = 1)

# number of events in event model
numEvents(bant.mdl)

# number of events in burst pulse (bp) detector model
numEvents(bant.mdl, "bp")

Run the code above in your browser using DataLab