tsEvaRunningMeanTrend {RtsEva} | R Documentation |
Calculate the running mean trend of a time series
Description
This function calculates the running mean trend of a given time series using a specified time window.
Usage
tsEvaRunningMeanTrend(timeStamps, series, timeWindow)
Arguments
timeStamps |
A vector of time stamps corresponding to the observations in the series. |
series |
A vector of numeric values representing the time series. |
timeWindow |
The length of the time window (in the same time units as the time stamps) used for calculating the running mean trend. |
Value
A list containing the running mean trend series and the number of observations used for each running mean calculation.
Examples
timeAndSeries <- ArdecheStMartin
timeStamps <- ArdecheStMartin[,1]
series <- ArdecheStMartin[,2]
timeWindow <- 365*30
result <- tsEvaRunningMeanTrend(timeStamps, series, timeWindow)
result$trendSeries
result$nRunMn
[Package RtsEva version 1.0.0 Index]