Portfolio Entropy
Portfolio entropy is the Shannon entropy of the weight vector, computed with natural logarithms. It measures how evenly capital is spread across the holdings: the equally weighted portfolio maximises it, and a single-name portfolio drives it to zero. The metric is a concentration diagnostic on the allocation, not a statistic of the return distribution.
What FolioLab computes
The entropy field is over the optimised weights. The input is the weight vector the run ships, never the realised return series, so no binning rule, no histogram and no return quantile takes part in the calculation.
- Natural logarithm. The unit is nats, not bits. A base-2 value would be larger by a factor of .
- Negative weights are clipped to zero before the vector is renormalised, so a short leg is not measured faithfully.
- The vector is renormalised to sum to one, and any weight at or below is dropped before the sum.
- Degenerate input returns 0.0. An empty weight map, or one whose weights sum to zero or less, gives exactly zero.
Overview
Shannon entropy, introduced by Claude Shannon in 1948 as the foundation of information theory, quantifies the average information content of a probability distribution. A long-only weight vector is already a probability distribution: the weights are non-negative and they sum to one. Entropy therefore applies to it directly, with no estimation step and no distributional assumption.
Read as a diversification measure, entropy answers a different question from variance. Variance asks how much the portfolio moves. Entropy asks how much of the portfolio sits in how few names. Bera and Park (2008) use the maximum-entropy principle as the diversification objective itself, and Zhou et al. (2013) survey the wider use of entropy measures in finance. The companion metric on FolioLab is the effective number of constituents, the inverse Herfindahl-Hirschman index on the same weight vector.
Mathematical Formulation
Shannon Entropy of the Weights
Let be the portfolio weights, with and . The portfolio entropy is:
By convention , which the implementation applies by dropping every weight at or below . The result is measured in nats because the logarithm is natural.
Bounds
Entropy is bounded by the number of holdings that carry a non-zero weight:
The upper bound is attained only by the equally weighted portfolio ( for all ). The lower bound of zero is attained when one asset holds the entire portfolio. Because the ceiling grows with , a raw entropy value is comparable across two portfolios only when they hold a similar number of names.
Normalised Entropy
Dividing by the ceiling removes the dependence on the holding count:
Normalised entropy ranges from 0 to 1, where 1 is the equally weighted allocation. FolioLab stores the unnormalised value ; divide by yourself if you need the normalised form.
Relation to the Effective Number of Constituents
The exponential of the entropy is an effective holding count, directly comparable with the inverse Herfindahl-Hirschman measure that FolioLab reports as effective_n:
Both collapse to for the equally weighted portfolio and to 1 for a single holding. They differ in how hard they punish a large weight: the inverse Herfindahl squares the weights, so it reacts more sharply to one dominant name than the entropy does.
Worked Example
Take four holdings. An equally weighted allocation gives:
Now concentrate the same four holdings into weights (0.70, 0.10, 0.10, 0.10):
The entropy falls from 1.386 to 0.940 nats. The matching effective counts are against , while the inverse Herfindahl measure falls from 4.00 to 1.92.
Advantages & Limitations
Advantages
- No estimation error: The weights are known exactly, so unlike a return-based statistic the value carries no sampling noise.
- Model-free: The measure assumes nothing about the return distribution, the covariance matrix, or the holding period.
- Single-number concentration: One value summarises a whole allocation, and it is maximised exactly by the equally weighted portfolio.
- Information-theoretic foundation: Grounded in a rigorous framework with deep connections to coding theory and statistical mechanics.
Limitations
- Blind to risk: Entropy sees only the weights. Two portfolios with identical weights on completely different assets score the same, whatever their volatility.
- Blind to correlation: Ten weights spread evenly across ten banks score exactly the same as ten weights spread across ten unrelated sectors.
- Holding-count dependence: The ceiling is , so raw values from portfolios of different size are not directly comparable.
- Short positions are clipped: A negative weight is set to zero before renormalisation, so the value understates the true exposure spread of a long-short portfolio.
- Not widely adopted: Entropy is not a standard reporting metric in the investment management industry, which limits comparability with external reports.
References
- Shannon, C. E. (1948). "A Mathematical Theory of Communication." Bell System Technical Journal, 27(3), 379-423.
- Bera, A. K., & Park, S. Y. (2008). "Optimal Portfolio Diversification Using the Maximum Entropy Principle." Econometric Reviews, 27(4-6), 484-512.
- Dionisio, A., Menezes, R., & Mendes, D. A. (2006). "An Econophysics Approach to Analysing Uncertainty in Financial Markets: An Application to the Portuguese Stock Market." European Physical Journal B, 50(1), 161-164.
- Zhou, R., Cai, R., & Tong, G. (2013). "Applications of Entropy in Finance: A Review." Entropy, 15(11), 4909-4931.
Not investment advice. Past performance is not indicative of future results.