View source: R/signal_spectrogram.R
signal_spectrogram | R Documentation |
This function creates spectrograms from seismic signals. It supports the standard spectrogram approach and the Welch method.
signal_spectrogram(
data,
time,
dt,
Welch = FALSE,
window,
overlap = 0.5,
window_sub,
overlap_sub = 0.5,
method = "periodogram",
cpu = NULL,
plot = FALSE,
...
)
data |
|
time |
|
dt |
|
Welch |
|
window |
|
overlap |
|
window_sub |
|
overlap_sub |
|
method |
|
cpu |
|
plot |
|
... |
Additional arguments passed to the function. |
Data containing NA
values is replaced by zeros and set to NA in the
output data set.
List
with spectrogram matrix, time and frequency vectors.
Michael Dietze
## load example data set
data("earthquake")
## calculate and plot PSD straight away
P <- signal_spectrogram(data = s$BHZ,
time = t,
dt = 1 / 200,
plot = TRUE)
## calculate and plot PSD with defined window sizes and the Welch method
P <- signal_spectrogram(data = s$BHZ,
time = t,
dt = 1 / 200,
window = 5,
overlap = 0.9,
window_sub = 3,
overlap_sub = 0.9,
Welch = TRUE,
plot = TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.