upDownTimesMetric: Up/down times for a channel

View source: R/upDownTimesMetric.R

upDownTimesMetricR Documentation

Up/down times for a channel

Description

The upDownTimesMetric() function determines the times at which data collection starts and stops within a seismic Stream.

Usage

upDownTimesMetric(st, min_signal, min_gap)

Arguments

st

a Stream object containing a seismic signal

min_signal

minimum duration of a Trace in seconds (default=30)

min_gap

minimum gap in seconds (default=60)

Details

This function uses the output of the getUpDownTimes method of Stream objects.

Value

A list with a single MultipleTimeValueMetric object is returned.

Note

See the seismic package for documentation on Stream objects and the getDataselect method.

Author(s)

Jonathan Callahan jonathan@mazamascience.com

See Also

getUpDownTimes

Examples

  ## Not run: 
# Open a connection to IRIS DMC webservices
iris <- new("IrisClient")

starttime <- as.POSIXct("2012-01-24", tz="GMT")
endtime <- as.POSIXct("2012-01-25", tz="GMT")

# Get the waveform
st <- getDataselect(iris,"AK","PIN","","BHZ",starttime,endtime)

# Create the upDownTimesMetric, ignoring Traces < 3 minutes and gaps of < 5 minutes
metricList <- upDownTimesMetric(st, min_signal=180, min_gap=300)
  
## End(Not run)

IRISMustangMetrics documentation built on April 28, 2022, 1:06 a.m.