Historical Conditional Value-at-Risk (Expected Shortfall): the mean loss in the worst alpha tail over a window.
Window length in observations.
Tail probability level in (0, 1); 0.05 means the 5% CVaR (average loss in the worst 5% of the window).
https://screamer.readthedocs.io/en/latest/ for the Python reference and full details.
Historical Conditional Value-at-Risk (Expected Shortfall): the mean loss in the worst alpha tail over a window.