What does Regimes, Tail Dependence and Barbells conclude, in numbers, about “Extreme Value Theory: From Tail Index to Expected Shortfall”?

Answer: Finally, the program computes the power of Kupiec's test. Over 250 trading days (about a year, the window commonly used in regulatory backtesting), a model whose true violation rate is 2 % (twice the nominal 1 %) has only a 24 % chance of being rejected; with a true rate of 1.5 %, only 11 %. Rejecting a 2 % model with about 80 % probability takes about 1,000 days. At 250 days the actual size of the test is 9.5 %, not 5 %, because of the discreteness of the binomial distribution. A year of backtesting that "does not reject" says almost nothing about whether a model is right.

Scope of the numbers: When a crisis comes, do assets fall together? How large must reserves and safety cushions be? This book presents mathematical models for teaching and research and is not investment advice. Marked boxes separate published evidence, runnable Python calculations (16 programs), classical sources and the author's models and hypotheses; all data in the book are fictional or simulated.

中文版

Data table

The numbers below are printed verbatim by the chapter's Python program and can be reproduced by running it. standard-library Python onlyprinted values that match the answer: 0.066, 0.071, 0.27, 0.290, 0.5, 0.54

Hill estimate of the tail index alpha (top k of 5,000 losses)
k25 50 100 200 400 800 1600
t33.40 3.22 2.84 2.42 2.27 1.82 1.14 (true 3)
normal10.06 9.17 6.60 5.18 3.74 2.60 1.29 (true: infinite)
mean excess e(u) = E[X - u | X > u] at empirical quantiles of the losses
quantile0.800 0.900 0.950 0.975 0.990
t30.97:1.08 1.62:1.23 2.32:1.47 3.24:1.66 4.66:1.95 (u:e)
normal0.86:0.54 1.27:0.49 1.66:0.40 1.95:0.39 2.36:0.27 (u:e)
a GPD with xi1/3 has e(u) linear with slope xi/(1 - xi) = 0.5;
the normal's e(u) falls like 1/u
GEV shape xi from maxima of blocks (probability-weighted moments)
t350 blocks of 100, 200 samples: median xi +0.290, 5-95 % +0.066 to +0.572
normal50 blocks of 100, 200 samples: median xi -0.109, 5-95 % -0.277 to +0.071

Key formula

\[G_\xi(x) = \exp\!\left\{-(1 + \xi x)^{-1/\xi}\right\}, \qquad 1 + \xi x > 0,\]
Show the full program
# Reading a tail: the Hill estimator of the tail index, the mean-excess function, and a
# GEV fit to block maxima by probability-weighted moments (Hosking, Wallis & Wood 1985).
# SIMULATED losses: Student t with 3 d.f. (true tail index alpha = 3, xi = 1/3) and the
# normal (xi = 0: no power tail at all). 5,000 observations each.
import math, random, statistics

def sample(kind, n, rng):
    if kind == "t3":
        return [rng.gauss(0, 1) / math.sqrt(rng.gammavariate(1.5, 2) / 3)
                for _ in range(n)]
    return [rng.gauss(0, 1) for _ in range(n)]

def hill(x, k):
    s = sorted(x, reverse=True)
    h = sum(math.log(s[i] / s[k]) for i in range(k)) / k
    return 1 / h                                   # estimated tail index alpha = 1/xi

def mean_excess(x, u):
    e = [v - u for v in x if v > u]
    return sum(e) / len(e), len(e)

def gev_pwm(m):
    m = sorted(m); n = len(m)
    b0 = sum(m) / n
    b1 = sum(i * m[i] for i in range(n)) / (n * (n - 1))
    b2 = sum(i * (i - 1) * m[i] for i in range(n)) / (n * (n - 1) * (n - 2))
    c = (2 * b1 - b0) / (3 * b2 - b0) - math.log(2) / math.log(3)
    k = 7.8590 * c + 2.9554 * c * c                # Hosking's k = -xi
    return -k

if __name__ == "__main__":
    rng = random.Random(1975)
    data = {kind: sample(kind, 5000, rng) for kind in ("t3", "normal")}
    print("Hill estimate of the tail index alpha (top k of 5,000 losses)")
    ks = (25, 50, 100, 200, 400, 800, 1600)
    print("   k     " + "".join(f"{k:7d}" for k in ks))
    for kind, x in data.items():
        print(f"   {kind:7s}" + "".join(f"{hill(x, k):7.2f}" for k in ks)
              + ("   (true 3)" if kind == "t3" else "   (true: infinite)"))
    print("mean excess e(u) = E[X - u | X > u] at empirical quantiles of the losses")
    qs = (0.80, 0.90, 0.95, 0.975, 0.99)
    print("   quantile" + "".join(f"{q:9.3f}" for q in qs))
    for kind, x in data.items():
        s = sorted(x); row = ""
        for q in qs:
            u = s[int(q * len(s))]; e, n = mean_excess(x, u)
            row += f"  {u:4.2f}:{e:4.2f}"
        print(f"   {kind:7s} " + row + "   (u:e)")
    print("   a GPD with xi = 1/3 has e(u) linear with slope xi/(1 - xi) = 0.5;")
    print("   the normal's e(u) falls like 1/u")
    print("GEV shape xi from maxima of blocks (probability-weighted moments)")
    for kind in ("t3", "normal"):
        est = []
        for _ in range(200):
            x = sample(kind, 5000, rng)
            est.append(gev_pwm([max(x[i:i + 100]) for i in range(0, 5000, 100)]))
        q = statistics.quantiles(est, n=20)
        print(f"   {kind:7s}: 50 blocks of 100, 200 samples: median xi {q[9]:+.3f},"
              f" 5-95 % {q[0]:+.3f} to {q[-1]:+.3f}")

Single source and citation

Fan, Y. (2026). Macro-Liquidity Regime Switching, Extreme Tail Dependence and Barbell Asset Allocation (Version 1.0.0), Chapter 2: Extreme Value Theory: From Tail Index to Expected Shortfall. 5D Library. https://doi.org/10.5281/zenodo.23828049

DOI: 10.5281/zenodo.23828049 · Read the monograph · 5DL-B-040 · v1.0.0 · CC-BY-NC-ND-4.0

BibTeX
@book{fan2026040,
  author    = {Fan, Yafu},
  title     = {Macro-Liquidity Regime Switching, Extreme Tail Dependence and Barbell Asset Allocation},
  year      = {2026},
  publisher = {5D Library},
  edition   = {1.0.0},
  doi       = {10.5281/zenodo.23828049},
  url       = {https://doi.org/10.5281/zenodo.23828049}
}

Other chapter answers in this book