pastas.stats.metrics.picp ========================= .. py:function:: pastas.stats.metrics.picp(obs: pandas.Series, bounds: pandas.DataFrame) Compute the prediction interval coverage probability (PICP). :param obs: Pandas Series with the observed time series and a DateTimeIndex. :type obs: pandas.Series :param bounds: DataFrame with the lower (first column) and upper (second columns) bounds of the prediction intervals. :type bounds: DataFrame .. rubric:: Notes The Prediction Interval Coverage Probability (PICP) is computed as follows: .. math:: PICP = \\frac{1}{N} \\sum_{i=1}^N a_i, a_i = \\begin{cases} 1 & \\text{if} h_i \\text{in} [\\hat{h_i}^L, \\hat{h_i}^U], \\ 0 & \\text{otherwise} \\end{cases} .. rubric:: Examples >>> import pandas as pd >>> import numpy as np >>> from pastas.stats import picp >>> obs = pd.Series(np.random.rand(100), ... index=pd.date_range("2000-01-01", periods=100)) >>> bounds = pd.DataFrame(np.random.rand(100, 2), index=obs.index) >>> picp(obs, bounds) .. !! processed by numpydoc !!