get_ewt_spectrum: Get EWT spectrum

Description Usage Arguments Value

View source: R/utils.R

Description

Given the spectrum of a time series vector this function will return its Empirical Wavelet Transformed spectrum.

Usage

1
2
3
4
5
6
7
get_ewt_spectrum(
  spectrum,
  npeaks = 3,
  fraction_min_peak_height = 0.1,
  min_peak_distance = 1,
  sampling_rate = 100
)

Arguments

spectrum

FFT spectrum as a two dimensional data frame with columns names as freq and pdf respectively n.freq x 2.

npeaks

Number of peaks to be captured.

fraction_min_peak_height

Minimum height (relative to maximum peak height) a peak has to have. Specified as fraction between 0 and 1.

min_peak_distance

The minimum distance (in indices) peaks. have to have to be counted.

sampling_rate

Sampling rate of the signal (by default it is 100 Hz).

Value

Emprical wavelet transformed spectrum of dimension n.freq x (npeaks + 1).


Sage-Bionetworks/mHealthTools documentation built on Sept. 21, 2020, 12:35 p.m.