Adding prediction interval to forecast
See original GitHub issueIs your feature request related to a current problem? Please describe. Most algorithms have a prediction interval also associated with the forecast. This could be implemented in an algorithm agnostic way also.
https://otexts.com/fpp2/prediction-intervals.html
Describe proposed solution
In predict
have an optional parameter, prediction_interval
which when set True.
returns not just forecast (yhat) , but also yhat_upper and yhat_lower based on the prediction interal.
Can use the sample Naive forecast logic mentioned here to implement this.
Describe potential alternatives Prophet, auto arima etc provides these prediction interval values.
Additional context This could also be used in plots for the forecast.
Issue Analytics
- State:
- Created 3 years ago
- Reactions:4
- Comments:9 (9 by maintainers)
Top Results From Across the Web
Add Prediction Intervals to your Forecasting Model
In this post, we introduced a method to produce prediction intervals as a way to provide uncertainty estimation in forecasting. The procedure is ......
Read more >3.5 Prediction intervals | Forecasting: Principles and ... - OTexts
The value of prediction intervals is that they express the uncertainty in the forecasts. If we only produce point forecasts, there is no...
Read more >3.3 - Prediction Interval for a New Response | STAT 501
In this section, we are concerned with the prediction interval for a new response, y n e w , when the ... Adding...
Read more >Prediction intervals when forecasting with machine learning ...
More formally, a prediction interval defines the interval within which the true value of the response variable is expected to be found with...
Read more >Better prediction intervals for time series forecasts
A prediction interval is a similar but not identical concept to a confidence interval. A prediction interval is an estimate of a value...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Thanks for the suggestion. We have this (or at least something similar) on our roadmap.
This has been released in v0.9.0.
Some models support specifying
num_samples
topredict()
, in which case they will return a “stochastic”TimeSeries
containingnum_samples
samples, which describe the distribution of the time series’ values. Some of the neural networks (at the momentRNNModel
andTCNModel
) are able to produce such stochastic forecasts if they are built specifying a certainlikelihood
parameter (e.g.,darts.utils.likelihood_models.GaussianLikelihoodModel()
to train the model with a negative Gaussian log likelihood loss).We went for such a sampling-based representation (instead, for instance, of returning fixed confidence intervals), because it allows (i) to compute arbitrary quantiles (using e.g.
TimeSeries.quantiles_df()
orTimeSeries.quantile_timeseries()
and (ii) for multivariate series it allows to capture the joint distribution over all components without assuming a specific parametric form.