@@ -241,6 +241,58 @@ Note that this means that using the split method will require to run three separ
241241to estimate the prediction intervals.
242242
243243
244+ 9. The ensemble batch prediction intervals (EnbPI) method
245+ =========================================================
246+
247+ The coverage guarantee offered by the various resampling methods based on the
248+ jackknife strategy, and implemented in MAPIE, are only valid under the "exchangeability
249+ hypothesis". It means that the probability law of data should not change up to
250+ reordering.
251+ This hypothesis is not revelant in many cases, notably for dynamical times series.
252+ That is why a specific class is needed, namely
253+ :class: `mapie.time_series_regression.MapieTimeSeriesRegressor `.
254+
255+ Its implementation looks like the jackknife+-after-bootstrap method. The
256+ leave-one-out (LOO) estimators are approximated thanks to a few boostraps.
257+ However the confidence intervals are like those of the jackknife method.
258+
259+ .. math ::
260+ \hat {C}_{n, \alpha }^{\rm EnbPI}(X_{n+1 }) = [\hat {\mu }_{agg}(X_{n+1 }) + \hat {q}_{n, \beta }\{ R_i^{\rm LOO} \}, \hat {\mu }_{agg}(X_{n+1 }) + \hat {q}_{n, (1 - \alpha + \beta )}\{ R_i^{\rm LOO} \} ]
261+ where :math: `\hat {\mu }_{agg}(X_{n+1 })` is the aggregation of the predictions of
262+ the LOO estimators (mean or median), and
263+ :math: `R_i^{\rm LOO} = |Y_i - \hat {\mu }_{-i}(X_{i})|`
264+ is the residual of the LOO estimator :math: `\hat {\mu }_{-i}` at :math: `X_{i}`.
265+
266+ The residuals are no longer considered in absolute values but in relative
267+ values and the width of the confidence intervals are minimized, up to a given gap
268+ between the quantiles' level, optimizing the parameter :math: `\beta `.
269+
270+ Moreover, the residuals are updated during the prediction, each time new observations
271+ are available. So that the deterioration of predictions, or the increase of
272+ noise level, can be dynamically taken into account.
273+
274+ Finally, the coverage guarantee is no longer absolute but asymptotic up to two
275+ hypotheses:
276+
277+ 1. Errors are short-term independent and identically distributed (i.i.d)
278+
279+ 2. Estimation quality: there exists a real sequence :math: `(\delta _T)_{T > 0 }`
280+ that converges to zero such that
281+
282+ .. math ::
283+ \frac {1 }{T}\sum _1 ^T(\hat {\mu }_{-t}(x_t) - \mu (x_t))^2 < \delta _T^2
284+
285+ The coverage level depends on the size of the training set and on
286+ :math: `(\delta _T)_{T > 0 }`.
287+
288+ Be careful: the bigger the training set, the better the covering guarantee
289+ for the point following the training set. However, if the residuals are
290+ updated gradually, but the model is not refitted, the bigger the training set
291+ is, the slower the update of the residuals is effective. Therefore there is a
292+ compromise to take on the number of training samples to fit the model and
293+ update the prediction intervals.
294+
295+
244296Key takeaways
245297=============
246298
@@ -266,6 +318,9 @@ Key takeaways
266318 theoretical and practical coverages due to the larger widths of the prediction intervals.
267319 It is therefore advised to use them when conservative estimates are needed.
268320
321+ - If the "exchangeability hypothesis" is not valid, typically for time series,
322+ use EnbPI, and update the residuals each time new observations are available.
323+
269324The table below summarizes the key features of each method by focusing on the obtained coverages and the
270325computational cost. :math: `n`, :math: `n_{\rm test}`, and :math: `K` are the number of training samples,
271326test samples, and cross-validated folds, respectively.
@@ -288,4 +343,8 @@ References
28834334th Conference on Neural Information Processing Systems (NeurIPS 2020).
289344
290345[3] Yaniv Romano, Evan Patterson, Emmanuel J. Candès.
291- "Conformalized Quantile Regression." Advances in neural information processing systems 32 (2019).
346+ "Conformalized Quantile Regression." Advances in neural information processing systems 32 (2019).
347+
348+ [7] Chen Xu and Yao Xie.
349+ "Conformal Prediction Interval for Dynamic Time-Series."
350+ International Conference on Machine Learning (ICML, 2021).
0 commit comments