Probability Distributions

Statistical Concepts

Understanding key statistical measures through visual demonstrations

🔵 Skewness

🟠 Kurtosis

⚖️ Value at Risk

Interactive Distributions

Manipulate parameters and observe real-time changes in probability distributions

Binomial Distribution

Models the number of successes in n independent trials with constant probability of success.

📊 Statistics

Mean (μ) 5.0
Variance (σ²) 2.5
Std Dev (σ) 1.58

Real-world Applications

  • Quality control in manufacturing
  • Medical test accuracy
  • Marketing campaign success rates
  • Financial risk modeling

VaR Portfolio Optimization

Interactive demonstration of risk optimization through portfolio rebalancing

Initial Portfolio
Fixed Loss Threshold (initial VaR₉₅)
Optimized Portfolio
What you're seeing: The red line stays fixed at the original VaR₉₅ level. As we optimize the portfolio (green curve), the distribution shifts right, dramatically reducing the probability of losses worse than our original threshold. The red shaded area shrinks from 5% to much less!
VaR₉₅ = 3.29%
Current Portfolio:
• Mean return: 0.0%
• Volatility: 2.0%
• 5th percentile: -3.29%
Progress: 0%

Proof: Quantile Functions Are Not Convex

Standard Convexity Test

For ANY function f to be convex, it must satisfy:

f(λx + (1-λ)y) ≤ λf(x) + (1-λ)f(y)

for all x, y in the domain and λ ∈ [0,1].

Applied to Quantiles

Here:

  • f = Qp (the quantile function)
  • x = X (first distribution)
  • y = Y (second distribution)
  • λx + (1-λ)y = Z (the mixture distribution)

So the test becomes:

Qp(mixture) ≤ λQp(X) + (1-λ)Qp(Y)

Finding Q0.6(X)

X is a degenerate distribution that always equals 2.

For any probability level p, including p = 0.6:

Q0.6(X) = 2

Finding Q0.6(Y)

Y is a degenerate distribution that always equals 10.

For any probability level p, including p = 0.6:

Q0.6(Y) = 10

What the Mixture Distribution Z Actually Is

The mixture Z = 0.3X + 0.7Y creates a discrete distribution:

  • Takes value 2 with probability 0.3
  • Takes value 10 with probability 0.7

Finding Q0.6(Z) - The Key Step

To find the 60th percentile of Z:

  • At value 2: cumulative probability = 0.3 < 0.6 ❌ (not enough)
  • At value 10: cumulative probability = 1.0 ≥ 0.6 ✅ (sufficient)

Therefore: Q0.6(Z) = 10

Our Numbers

  • Left side: Qp(Z) = 10 (quantile jumps to 10)
  • Right side: 0.3(2) + 0.7(10) = 7.6 (smooth weighted average)
  • Test: 10 ≤ 7.6

Convexity Fails!

The quantile function gives us 10 for the mixture, but convexity would require it to be ≤ 7.6. The quantile jumps discontinuously from 2 to 10, skipping over the weighted average of 7.6 entirely.

Since 10 > 7.6, the quantile function violates convexity.

This discontinuous jump is exactly why VaR optimization is non-convex and computationally problematic. Standard optimization algorithms fail because the risk landscape has sudden jumps and multiple local optima.