|
5 | 5 | ``ConditionalSplitConformalRegressor`` |
6 | 6 | is used to reproduce a part of the paper experiments of Gibbs et al. (2023) in |
7 | 7 | their article [1] which we argue is a good procedure to get adaptative |
8 | | -prediction intervals (PI) and a guaranteed coverage on all sub groups of |
| 8 | +prediction intervals and a guaranteed coverage on all sub groups of |
9 | 9 | interest. |
10 | 10 |
|
11 | 11 | For a given model, the simulation uses the |
12 | 12 | ``ConditionalSplitConformalRegressor`` class, on a synthetic dataset first considered by Romano et al. (2019) |
13 | | -[2], and compares the bounds of the PIs with the standard SplitConformalRegressor. |
| 13 | +[2], and compares the bounds of the intervals with the standard ``SplitConformalRegressor``. |
14 | 14 |
|
15 | 15 | This simulation is carried out to check that the conditional method implemented in |
16 | | -MAPIE gives the same results as [1], and that the bounds of the PIs are |
| 16 | +MAPIE gives the same results as [1], and that the bounds of the intervals are |
17 | 17 | obtained. |
18 | 18 |
|
19 | 19 | [1] Isaac Gibbs, John J. Cherian, Emmanuel J. Candès (2023). |
|
24 | 24 | 33rd Conference on Neural Information Processing Systems (NeurIPS 2019). |
25 | 25 | """ |
26 | 26 |
|
27 | | -# sphinx_gallery_thumbnail_number = 2 |
| 27 | +# mkdocs_gallery_thumbnail_number = 2 |
28 | 28 |
|
29 | 29 | import matplotlib.pyplot as plt |
30 | 30 | import numpy as np |
@@ -401,8 +401,14 @@ def plot_results(X_test, y_test, n_trials=20, experiment="Groups"): |
401 | 401 | # prediction. Groups are defined with intervals of $x$. The second experiment |
402 | 402 | # illustrates the case of covariate shift. |
403 | 403 |
|
| 404 | +############################################################################### |
| 405 | +# Group-conditional experiment |
| 406 | +# ----------------------------------------------------------------------------- |
404 | 407 | plot_results(X_test, y_test, experiment="Groups") |
405 | 408 |
|
| 409 | +############################################################################### |
| 410 | +# Covariate shift experiment |
| 411 | +# ----------------------------------------------------------------------------- |
406 | 412 | plot_results(X_test, y_test, experiment="Shifts") |
407 | 413 |
|
408 | 414 |
|
|
0 commit comments