FeatFWHM: Find Full Width at Half maximum by spline interpolation

Description Usage Arguments Value

View source: R/single_peak_features.R

Description

Find Full Width at Half maximum by spline interpolation

Usage

1
2
FeatFWHM(y, x = seq_along(y), n = 30 * length(x), method = "walk",
  basal = min(y))

Arguments

y

numeric, typically a signal recorded over time at x.

x

numeric, typically time vector

n

numeric, number of points returned by interpolation. Increase improves accuracy of FWHM estimation.

method

one of "minimum" or "walk". Walk method is highly recommended as it avoids many pitfalls of the minimum method. Minimum simply pick the points which values are the closest to the half of the max value. Walk method walks left and right from the maximum point, and stops whenever half max value is crossed.

basal

Normalization constant to bring base of the signal at 0.

Value

A list of 3: left and right represent the value of interpolated x at which half of the maximum in y is reached. fwhm is the difference between right and left.


majpark21/TSexploreR documentation built on Oct. 16, 2019, 2:46 p.m.