Top Leaderboard
Markets

Historical Volatility Hv

Ad — article-top

Historical volatility (HV) is a statistical measure of how much the price of a security (stock, index, ETF, etc.) has varied over a past period. Practically, HV is the standard deviation of the security’s past returns, usually computed over a fixed lookback (e.g., 10, 30, 252 trading days) and often annualized so it can be compared across instruments or used in option models.

Source: Investopedia — “Historical Volatility (HV)” (summary and interpretation adapted).

Why HV matters (brief)
– It quantifies past price dispersion and thus the magnitude of typical price moves.
– Traders compare HV to implied volatility (IV) to judge whether options look cheap or expensive.
– Risk managers and systematic strategies use HV for position sizing, stop placement, volatility targeting, and constructing volatility-based indicators (Bollinger Bands, volatility filters).

How HV is calculated (concept & formulas)
1. Choose your returns type:
• Log returns (recommended for time-additivity): r_t = ln(P_t / P_{t-1})
• Simple returns: R_t = (P_t − P_{t-1})/P_{t-1}

2. Compute the sample standard deviation of the returns:
• Sample SD: s = sqrt( (1/(N−1)) * Σ (r_t − r̄)^2 )

3. Annualize (if using daily returns):
• Annualized HV = s × sqrt(TradingDaysPerYear)
• Common convention: TradingDaysPerYear ≈ 252, so annualize with sqrt(252)
• For weekly returns use sqrt(52); for monthly returns use sqrt(12)

Step‑by‑step practical calculation (daily prices)
1. Get consecutive daily closing prices for the lookback period (e.g., 30, 90, 252 days).
2. Compute daily log returns: r_t = ln(P_t / P_{t−1}).
3. Compute the mean of the returns r̄ (or use zero-mean if desired; but standard sample SD uses r̄).
4. Compute the sample SD s of the daily returns.
5. Annualize: HVannual = s × sqrt(252).
6. Optionally smooth with a rolling window to produce a volatility time series.

Small numeric example (5 days)
Prices: 100, 102, 101, 103, 104
Daily log returns:
– r1 = ln(102/100) = 0.019802
– r2 = ln(101/102) = −0.009852
– r3 = ln(103/101) = 0.019604
– r4 = ln(104/103) = 0.009662
Sample SD of these 4 returns ≈ 0.01393 (1.393% daily)
Annualized HV ≈ 0.01393 × sqrt(252) ≈ 0.221 → 22.1% annual HV

How to compute HV in Excel or Python
– Excel:
1. Column A: prices.
2. Column B (log returns): =LN(A2/A1) and fill down.
3. SD (sample): =STDEV.S(B2:Bn)
4. Annualize: =STDEV.S(B2:Bn)*SQRT(252)

• Python / pandas:
import numpy as np
import pandas as pd
prices = pd.Series(…) # daily closes
returns = np.log(prices / prices.shift(1)).dropna()
daily_sd = returns.std(ddof=1)
annual_hv = daily_sd * np.sqrt(252)

Choosing lookback and method — practical guidance
– Short lookbacks (10–30 days): responsive to regime changes but noisy.
– Medium lookbacks (60–90 days): balance between responsiveness and stability.
– Long lookbacks (180–252 days): smoother, reflect long-term risk but slow to react.
– Use rolling HV to see changes over time.
– Consider EWMA or GARCH if you need a volatility forecast rather than a backward-looking summary.

How traders and investors use HV (practical steps)
1. Compare to implied volatility:
• If IV > HV (historical), options may imply higher future volatility — sellers might consider premium generation strategies (with careful risk control).
• If IV < HV, options look relatively cheap — buyers might find better value.
• Always check reasons for discrepancy (earnings, events) before trading.

2. Position sizing and risk:
• Use HV to scale position size (smaller positions when HV is high to keep dollar volatility constant).
• Volatility targeting: adjust exposure so portfolio volatility stays near a target.

3. Stops and margin:
• Wider stop-loss distances in high-HV names and tighter stops in low-HV names.
• Expect higher margin requirements and slippage in high-HV environments.

4. Technical indicators:
• Bollinger Bands: MA ± k × (rolling SD). Bands expand with HV and contract during calm periods.
• Volatility filters: trade only when HV crosses a threshold or when HV diverges from IV.

5. Portfolio construction:
• Use HV to diversify by combining assets with different volatilities or to implement volatility parity / risk parity.

Limitations and cautions
– HV is backward-looking — it describes past dispersion, not guaranteed future volatility.
– Sensitivity to lookback: different windows give different HV values.
– Outliers and jumps (e.g., flash crashes, one-off news) can skew HV.
– Liquidity and stale prices can distort returns and measured volatility, especially for thinly traded securities.
– HV does not capture directional bias (it measures dispersion around the mean only).
– Comparing HV across assets needs consistent return frequency and annualization convention.

Advanced/alternative approaches
– EWMA (exponentially weighted moving average): gives more weight to recent returns and is common in risk systems.
– GARCH-family models: attempt to model and forecast changing volatility dynamics.
– Realized volatility using intraday returns (more precise but data-intensive).
– Use both HV and forecasted volatility (GARCH/EWMA) plus IV to build a fuller view.

Practical checklist before using HV in a trade
1. Confirm data quality (adjusted closes for dividends, stock splits).
2. Choose an appropriate lookback and method (simple rolling, EWMA, GARCH).
3. Compute HV and annualize consistently (document your convention).
4. Compare HV to IV and peers in the same sector/market.
5. Factor HV into position sizing, stops, and expected slippage.
6. Recompute on a regular schedule and monitor changes for regime shifts.

Further reading / source
– Investopedia — “Historical Volatility (HV)” (used as the basis for definitions and interpretation)

– Compute HV for a specific stock/ticker and lookback period (give me the ticker and dates).
– Provide an Excel template or a ready-to-run Python notebook that computes rolling HV, compares it to IV, and plots both.

Ad — article-mid