Calculate trend lines and forecast based on seasonal data.
The chart was created with wuct/elm-charts.
elm package install ggb/elm-trend
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.
Ideas for future development:
- Implementing ARIMA
- Multivariant regression and other regression types