pysteps.postprocessing.ensemblestats.banddepth(X, thr=None, norm=False)#

Compute the modified band depth (Lopez-Pintado and Romo, 2009) for a k-member ensemble data set.

Implementation of the exact fast algorithm for computing the modified band depth as described in Sun et al (2012).

  • X (array_like) – Array of shape (k, m, …) representing an ensemble of k members (i.e., samples) with shape (m, …).

  • thr (float) – Optional threshold for excluding pixels that have no samples equal or above the thr value.


out – Array of shape k containing the (normalized) band depth values for each ensemble member.

Return type



Lopez-Pintado, Sara, and Juan Romo. 2009. “On the Concept of Depth for Functional Data.” Journal of the American Statistical Association 104 (486): 718–34.

Sun, Ying, Marc G. Genton, and Douglas W. Nychka. 2012. “Exact Fast Computation of Band Depth for Large Functional Datasets: How Quickly Can One Million Curves Be Ranked?” Stat 1 (1): 68–74.