The fast Fourier transform is used to extract the seasonal signal of a time series. The significant frequencies are found from among periods of length 2-, 3-, 4-, 6-, 12-, and 18-months.
The signal may be specified as stationary or non-stationary. If a non-stationary fit is allowed, simple linear regression estimates the long term linear trend. The seasonal signal is calculcated from the residuals.
Predicted flow (and corresponding residual) at each time point is calculated from seasonal signal and, if non-stationary, long term trend coefficient.
fourierAnalysis(x, stationary=F)## S3 method for class 'ssignal' plot(x, plot.type="hydrograph",...)
Arguments
x: An object of class streamflow
stationary: Logical; defaults to FALSE.
plot.type: Indicates the type of plot to create. The default "hydrograph" produces a plot of ordinary day and log normalized discharge, with the seasonal signal overlaid. "auto.corr" produces a plot of daily autocorrelation as calculated from the residual flows.
...: Other parameters.
Returns
An object of class ssignal with items - signal: Data matrix augmented to included predicted and residual values.
terms: Matrix containing amplitude, phase, and frequency of seasonal signal.
detrend.fit: An lm object from regression of discharge on index of observation.
logps.regression: An lm object from regression of log power spectrum on log frequency (where log frequencies have seasonal signal removed.)
rms: list containing RMS amplitude for noise, RMS amplitude for signal, and signal-to-noise ratio.