MyNixOS website logo
Description

Time Series Forecasting Using 23 Individual Models.

Runs multiple individual time series models, and combines them into an ensembles of time series models. This is mainly used to predict the results of the monthly labor market report from the United States Bureau of Labor Statistics for virtually any part of the economy reported by the Bureau of Labor Statistics, but it can be easily modified to work with other types of time series data. For example, the package was used to predict the winning men's and women's time for the 2024 London Marathon.

ForecastingEnsembles

The goal of ForecastingEnsembles is to automatically run 23 forecasting models, return 19 plots and tables.

Installation

You can install the development version of ForecastingEnsembles like so:

devtools::install_github("InfiniteCuriosity/ForecastingEnsembles")

Example

This is a basic example which shows you how to solve a common problem of forecasting data that is reported weekly, monthly or quarterly. The Forecasting Ensembles package only needs the data, and it will build 23 models:

Linear1 = TSLM(Value ~ season() + trend()),
Linear2 = TSLM(Value),
Linear3 = TSLM(Value ~ season()),
Linear4 = TSLM(Value ~ trend()),
Arima1 = ARIMA(Value ~ season() + trend(), stepwise = TRUE, greedy = TRUE, approximation = TRUE),
Arima2 = ARIMA(Value ~ season(), stepwise = TRUE, greedy = TRUE, approximation = TRUE),
Arima3 = ARIMA(Value ~ trend(), stepwise = TRUE, greedy = TRUE, approximation = TRUE),
Arima4 = ARIMA(Value),
Deterministic = ARIMA(Value ~ 1 + pdq(d = 0), stepwise = TRUE, greedy = TRUE, approximation = TRUE),
Stochastic = ARIMA(Value ~ pdq(d = 1), stepwise = TRUE, greedy = TRUE, approximation = TRUE),
Ets1 = ETS(Value ~ season() + trend()),
Ets2 = ETS(Value ~ trend()),
Ets3 = ETS(Value ~ season()),
Ets4 = ETS(Value),
Holt_Winters_Additive = ETS(Value ~ error("A") + trend("A") + season("A")),
Holt_Winters_Multiplicative = ETS(Value ~ error("M") + trend("A") + season("M")),
Holt_Winters_Damped = ETS(Value ~ error("M") + trend("Ad") + season("M")),
Fourier1 = ARIMA((Value) ~ fourier(K = 1) + PDQ(0, 0, 0)),
Fourier2 = ARIMA((Value) ~ fourier(K = 2) + PDQ(0, 0, 0)),
Fourier3 = ARIMA((Value) ~ fourier(K = 3) + PDQ(0, 0, 0)),
Fourier4 = ARIMA((Value) ~ fourier(K = 4) + PDQ(0, 0, 0)),
Fourier5 = ARIMA((Value) ~ fourier(K = 5) + PDQ(0, 0, 0)),
Fourier6 = ARIMA((Value) ~ fourier(K = 6) + PDQ(0, 0, 0))
library(ForecastingEnsembles)
## Forecasting(time_series_data = Oct_2024_all_nonfarm, train_amount = 0.60, number_of_intervals_to_forecast = 1, use_parallel = "Y", time_interval = "M")

The Forecasting Ensembles package returns:

Plot of the value of the time series Plot of individual seasons Head of the data Tail of the data Plot of the trend Plot of the seasonally adjusted data Plot of the decomposition Plot of anomalies Plot of subseasons Plot of multiple lags Table of time series features Table of time series quartiles Table of the best model forecast Plot of the best model forecast Plot of best autocorrelation function (ACF) Plot of the best model histogram of the residuals Plot of the best model actual vs predicted Plot of the best model actual vs residuals Plot of the best model baseline data.

Metadata

Version

0.5.0

License

Unknown

Platforms (75)

    Darwin
    FreeBSD
    Genode
    GHCJS
    Linux
    MMIXware
    NetBSD
    none
    OpenBSD
    Redox
    Solaris
    WASI
    Windows
Show all
  • aarch64-darwin
  • aarch64-freebsd
  • aarch64-genode
  • aarch64-linux
  • aarch64-netbsd
  • aarch64-none
  • aarch64-windows
  • aarch64_be-none
  • arm-none
  • armv5tel-linux
  • armv6l-linux
  • armv6l-netbsd
  • armv6l-none
  • armv7a-linux
  • armv7a-netbsd
  • armv7l-linux
  • armv7l-netbsd
  • avr-none
  • i686-cygwin
  • i686-freebsd
  • i686-genode
  • i686-linux
  • i686-netbsd
  • i686-none
  • i686-openbsd
  • i686-windows
  • javascript-ghcjs
  • loongarch64-linux
  • m68k-linux
  • m68k-netbsd
  • m68k-none
  • microblaze-linux
  • microblaze-none
  • microblazeel-linux
  • microblazeel-none
  • mips-linux
  • mips-none
  • mips64-linux
  • mips64-none
  • mips64el-linux
  • mipsel-linux
  • mipsel-netbsd
  • mmix-mmixware
  • msp430-none
  • or1k-none
  • powerpc-netbsd
  • powerpc-none
  • powerpc64-linux
  • powerpc64le-linux
  • powerpcle-none
  • riscv32-linux
  • riscv32-netbsd
  • riscv32-none
  • riscv64-linux
  • riscv64-netbsd
  • riscv64-none
  • rx-none
  • s390-linux
  • s390-none
  • s390x-linux
  • s390x-none
  • vc4-none
  • wasm32-wasi
  • wasm64-wasi
  • x86_64-cygwin
  • x86_64-darwin
  • x86_64-freebsd
  • x86_64-genode
  • x86_64-linux
  • x86_64-netbsd
  • x86_64-none
  • x86_64-openbsd
  • x86_64-redox
  • x86_64-solaris
  • x86_64-windows