Estimate Alpha, Hurst Exponent and Fractal Dimension through log-log slope.
fd_psd(
y,
fs = NULL,
removeTrend = c("no", "poly", "adaptive", "bridge")[2],
polyOrder = 1,
standardise = c("none", "mean.sd", "median.mad")[2],
fitMethod = c("lowest25", "Wijnants", "Hurvich-Deo")[3],
doPlot = FALSE,
returnPlot = FALSE,
returnPLAW = FALSE,
returnInfo = FALSE,
silent = FALSE,
noTitle = FALSE,
tsName = "y"
)
A numeric vector or time series object.
Sample rate (default = NULL
)
standardise the series (default = TRUE
).
Method to decide on a frequency range for log-log fit. Can be one of: "lowest25","Wijnants","Hurvich-Deo" (default). See details for more info.
Return the log-log spectrum with linear fit (default = TRUE
).
Return ggplot2 object (default = FALSE
)
Return the power law data (default = FALSE
)
Return all the data used in SDA (default = FALSE
)
Run in silent-ish mode (default = TRUE)
Do not generate a title (only the subtitle)
Name of y added as a subtitle to the plot
Subtract linear trend from the series (default = TRUE
).
A list object containing:
A data matrix PLAW
with columns freq.norm
, size
and bulk
.
Estimate of scaling exponent alpha
based on a fit over the lowest 25\
Estimate of the the Fractal Dimension (FD
) using conversion formula's reported in Hasselman(2013).
Information output by various functions.
Calls function stats::spec.pgram()
to estimate the scaling exponent of a timeseries based on the periodogram frequency spectrum. After detrending and normalizing the signal (if requested), stats::spec.pgram()
is called using a cosine taper = 0.5.
A line is fitted on the periodogram in log-log coordinates. The full range is fitted as well as one of three fit-ranges:
lowest25
- The 25\
Wijnants
- The 50 lowest frequencies (Wijnants et al., 2012)
Hurvich-Deo
- The Hurvich-Deo estimate (Hurvich & Deo, 1999)
Hasselman, F. (2013). When the blind curve is finite: dimension estimation and model inference based on empirical waveforms. Frontiers in Physiology, 4, 75. https://doi.org/10.3389/fphys.2013.00075
Hurvich, C.M., & Deo, R.R. (1999). Plug-in Selection of the Number of Frequencies in Regression Estimates of the Memory Parameter of a Long Memory Time Series. Journal of Time Series Analysis, 20(3), 331–341.