ggb/elm-trend

Regression and time series forecasting


License
BSD-3-Clause
Install
elm-package install ggb/elm-trend 1.0.2

Documentation

elm-trend

Calculate trend lines and forecast based on seasonal data.

The github-page shows a nice example chart.

The chart was created with wuct/elm-charts.

Installation

elm package install ggb/elm-trend

Usage

Usage is straightforward:

import Linear
import Seasonal

data = 
  [ 362, 385, 432, 341, 382, 409, ... ]

-- Create linear trend function
linearTrend = Linear.regression data

-- Seasonal forecast
period = 4
forecastData = Seasonal.forecast period

Take a look at example/SeasonalTest.elm for a more detailed example.

Future

Ideas for future development:

  • Implementing ARIMA
  • Multivariant regression and other regression types