naive_forecast: Naive forecasting

View source: R/deepML.r

naive_forecastR Documentation

Naive forecasting

Description

Naive forecasting

Usage

naive_forecast(x, drift = 0, na = NA)

Arguments

x

A vector, usually a numeric vector.

drift

The number of periods used to calculate the change over time (it's called a drift). If drift is more than 1 the mean value of the changes over time is used; default 0.

na

The value, default NA, used for gaps caused by the drift in the resulting vector.

Details

The following naive forecast approaches are implemented:

  • Random Walk: y(t+1) = y(t)

  • One drift: y(t+1) = y(t) + [y(t)-y(t-1)]

  • Many drifts: y(t+1) = y(t) + [(1/drifts) * \sum ([y(t)-y(t-1)])]

Value

A series of naive predicted values based upon x.

See Also

Other Machine Learning: cross_validation_split(), decision_tree(), k_nearest_neighbors(), moving_average(), naive_bayes(), predict.decisiontree(), predict.kmeans(), predict.naivebayes()


stschn/deepANN documentation built on June 25, 2024, 7:27 a.m.