How to use Z-score normalization to correctly compare data of different scales and time horizons in financial analysis.
What is Z-score normalization?
DEFINITION
Z-score normalization is an advanced normalization method that accounts not only for the scale of the data but also for the trend, and adapts to the time horizon for correct comparison of moves of different durations.
Z-score normalization: making moves comparable
CORE IDEA
In time series analysis and machine learning we often need to compare events on different time horizons and scales. The problem is that "large" moves automatically look more important than "small" ones, even when in relative terms they are equally strong.
Why dividing by the standard deviation alone does not save you:
- It removes scale but does not account for the average trend
- It does not make data on different horizons comparable
- Long horizons still look "noisier" because of accumulated volatility
The essence of Z-score normalization
The method simultaneously:
- Subtracts the expected move — removing the predictable part and leaving only the deviation from normal
- Scales by the horizon length — accounting for the fact that volatility grows proportionally to the square root of time
As a result, every change is translated into "units of surprise" — how unusual it is compared to the typical behavior of the series.
Intuitive example
COMPARABLE MOVES
A +1% move in 1 hour and a +2% move in 4 hours can be equally unusual, even though the second is larger in absolute terms. After Z-score normalization both receive the same "strength score" and become directly comparable.
Why it matters
BOTTOM LINE
Z-score normalization is a way to bring any time horizons and scales into a single coordinate system, where each step is rated by its "surprise" rather than by raw numbers.
- Signals from different timeframes become comparable
- Systematic bias from trend is removed
- Analytics and model training rely on deviations rather than absolute values
- Forecast robustness and statistical inference accuracy improve
The problem with classical normalization
PLAIN DIVISION BY STD
In classical normalization we just divide the value by the standard deviation: delta_h /= pnl_std. This removes the data scale but does not account for the mean and does not adapt to the time horizon. Result: trend is not separated from random fluctuations, and horizons of different lengths become incomparable.
Solution: Z-score normalization
Z-SCORE WITH HORIZON
Z-score normalization solves both problems.
delta_h = (delta_h - pnl_mean × h_) / (pnl_std × √h_)
Subtracting the expected trend
EXPECTED CHANGE BY HORIZON (MEAN PNL = 0.001)
Over 1 minute: 0.001 × 1 = 0.001. Over 5 minutes: 0.001 × 5 = 0.005. Over 10 minutes: 0.001 × 10 = 0.01. By subtracting this trend we keep only the "unexpected" move that actually matters for analysis.
Scaling by the time horizon
VOLATILITY GROWS AS √T
Over 1 minute: std × √1 = std. Over 4 minutes: std × √4 = std × 2. Over 9 minutes: std × √9 = std × 3. This accounts for the fact that longer horizons naturally fluctuate more.
Practical example
pnl_mean = 0.001 # Mean PNL per minute pnl_std = 0.002 # PNL std per minute Horizon 1 minute: delta_h = 0.003 normalized_1 = (0.003 - 0.001 × 1) / (0.002 × √1) = 1.0 Horizon 4 minutes: delta_h = 0.008 normalized_4 = (0.008 - 0.001 × 4) / (0.002 × √4) = 1.0
SAME RESULT
The result is the same — 1.0. Both moves are equally "strong" relative to their horizons.
Mathematical formula
Z-score normalization: Z = (x - μ × h) / (σ × √h) where: x — the input value μ — mean per unit time σ — standard deviation per unit time h — time horizon Interpretation: • Z = 0 — move matches the expected trend • Z = ±1 — one standard deviation from expected • Z = ±2 — two standard deviations from expected
Why it matters in trading
SIGNAL COMPARABILITY
Signals on different timeframes become comparable — a 1% move in a minute and a 2% move in 4 minutes can carry the same significance.
BIAS REMOVAL
Bias from a long-term trend is removed — we focus on unexpected moves rather than the overall market direction.
MODEL QUALITY
Model training quality and statistical inference correctness improve thanks to normalized data.
Comparison of normalization methods
Method — Formula — Trend-aware — Horizon-aware — Applicability Classical — x / std — No — No — Limited Min-Max — (x - min) / (max - min) — No — No — Limited Z-score — (x - μ) / σ — Yes — No — Good Z-score with horizon — (x - μ×h) / (σ×√h) — Yes — Yes — Excellent
When to use Z-score normalization
- Multi-timeframe analysis: when comparing signals from different time horizons — minute, hourly, daily data
- Trending markets: when a long-term trend is present in the data and may distort short-term move analysis
- Machine learning: when training models on data with different time horizons to ensure correct comparisons
- Statistical analysis: for correct statistical tests and significance estimation of moves of different durations
Practical implementation
Step-by-step rollout plan:
- Compute base statistics — mean and standard deviation per unit time
- Define horizons — for which time periods normalization is needed
- Apply the formula — use Z-score normalization with horizon
- Verify results — make sure normalized values have the expected distribution
- Integrate into the model — use normalized data for training and forecasting
Use cases
ALGORITHMIC TRADING
Normalizing signals from different timeframes for uniform decision-making regardless of analysis horizon.
RISK MANAGEMENT
Risk assessment on different time horizons accounting for the natural growth of volatility with the period.
Key takeaways
SUMMARY
Z-score normalization is an advanced method that accounts for trend and time horizon. It removes trend bias by focusing on unexpected moves, accounts for horizon (volatility grows as √t), provides comparability across scales, and improves analysis quality especially in multi-timeframe tasks.
Philosophy
UNITS OF SURPRISE
Essentially, Z-score normalization translates data into "units of surprise", letting you objectively compare moves of different scales and durations. This is especially important in trading, where decisions must be based on the relative significance of moves rather than their absolute size.