In memoriam of Valentin Afraimovich (1945-2018), a visionary scientist, respected colleague, generous mentor, and loyal friend
In the famous book "The intelligent investor", Benjamin Graham had advised not wasting time at forecasting how the market will perform in the future, as markets are fickle and market prices are largely meaningless. Instead, he taught that the intelligent investor should focus at the diligent financial evaluation of company’s market value, buying stocks that are clearly underpriced in the market. These opportunities are hard to find, but worth waiting for . Nowadays, we have enough publicly available historical data on stock market prices and the adequate mathematical methods in our hands to confirm or deny the conclusions of the father of value investing and security analysis.
We have investigated the recent five year stock price data for the components of the Standard & Poor’s 500 (S&P 500) selected by a committee that assesses the company’s market capitalization (must be greater than or
equal to $6.1 bln USD), liquidity, domicile, public float, sector classification, financial viability, and length of time publicly traded and stock exchange. The companies selected by the S&P 500 committee are representative of the industries in the United States economy.
The efficient-market hypothesis (EMH) states that asset prices fully reflect all available information  though it is impossible to ascertain what a stock should be worth under an efficient market, since investors value stocks differently. Random events are entirely acceptable under an efficient market, and it is unknown how much time prices need to revert to fair value, so that the price remains uncertain at every moment of time and over any time horizon. Therefore, it is important to ask whether EMH undermines itself in its allowance for random occurrences or environmental eventualities. In our work, we suggest a conceptually novel answer resolving this paradox by demonstrating that uncertainty of a stock state in phase space (specified by the stock daily return and its time derivative, roughness) always contain a quantifiable information component that can neither be predicted from any available data (whether historical, new, or hidden "insider" information), nor has any repercussion for the future stock behavior, but which holds on to the ephemeral present only ("ephemeral information", see Sec. 4). Although the price remains profoundly uncertain, uncertainty does not affect the global ability of financial market to correct itself by instantly changing to reflect new public information.
We study predictability of market states and stock prices of individual companies by reconstructing a discrete model of S&P 500 phase space, in which every component of S&P 500 is characterized by the daily return and roughness of the stock, and the market state corresponds to a certain distribution of stock in phase space.
The novelty of our approach is twofold.
First, in Sec. 4.1, we have developed the novel concept of predictability of states in phase space. Our approach is based on the idea that with some probability a state might be a t-day precursor of another state in phase space. The introduced measure of t-day predictability of a state is a sum of all information components from its t-day precursors. From such a point of view, Markov chains are characterized by the maximum predictability, as any state of a Markov chain is a predictor for any other state of the chain for all t with probability 1. The total amount of predictable information for any state of the Markov chain equals the total information content of the chain.
Second, in Sec. 4.2, we have proposed the novel methodology for a quantitative assessment of the amounts of predictable and unpredictable information in any stochastic process whenever an empirical transition matrix between the states observed over a certain time horizon becomes available. The proposed technique is an extension of the famous Ulam’s method  for approximating invariant densities of dynamical systems.
The following conclusions can be drawn from the present study:
- Long-range forecasts based on observed stock price time series might be efficient only for the frequently observed events in market phase space.
- Short-range forecasts (1-3 days ahead) of rear events (such as market crushes) might be efficient if and only if the predicted states are resulted from the processes of exponential decay (growth) in time.
- Stocks have different ’mobility’ in phase space. Mobility of a stock is usually irrelevant to the market capitalization weight of the company. The time series for highly mobile stocks might contain more predictable information for the efficient forecasting of the future states in phase space than the time series corresponding to the less mobile stocks.
Interestingly, the relations between predictable and unpredictable information in the stock price time series S&P 500, as well as between the amounts of predictable information on the future state of a stock available from the historic time series and from the present state alone are resembling those of unfair coin tossing, in which each state repeats itself with the probability 0 ≤ p ≤ 1.
2 Data source, data validation and preparation
Data on the individual stock prices of S&P 500 constituents for five years from 08/12/2013 to 08/09/2018 (i.e., 1,259 trading days in total) were acquired using The Investor’s Exchange API, the Python script is available at https://github.com/CNuge/kaggle-code/blob/master/stock_data We have chosen the largest data set publicly available for free and verifiable from different data sources. The data set contains price of the stock at market open, highest price reached in the day, lowest price in the day, price of the stock at market close, number of shares traded labeled by their ticker names for the most of S&P 500 companies during the studied period. We have used individual stock prices at market close since this information was always present in the data set. Moreover, in order to preserve consistency of our data, only 468 companies were considered; those selected were present in S&P 500 index throughout the entire observation period, and comprise 98.78% of S&P 500 total market weight. The other 37 constituents were excluded from the study because their presence in the index was inconsistent, and their stock prices were corrupted. The data set has been verified using Yahoo Finance. Computations were made using Python’s numerical libraries, such as NumPy and Pandas, Maple and Matlab to make sure the consistency of computations and eliminate possible errors.
3 The discrete model of Standard & Poor’s 500 phase space
We use the classical concept of phase space as a collection of all states specified by the observed values of the one-day investment return (as a ’position’):
where Price(t) is the price of the stock at market close, and t runs over trading days;
and its time derivative,
known as roughness (as a ’momentum’) . A stock is represented by a point in phase space accordingly its daily return and roughness. The stock’s price evolving over time traces a path in phase space (a trajectory) representing the set of states in a phase plot (see Fig. 1). The state of the market corresponds to a certain distribution and coherent movements of points in phase space.
For the sake of computational feasibility, the 5-year range of return values (minimum −0.53404886 and maximum of 0.3433584) as well as 5-year range of roughness values (minimum −0.59823906 and maximum 0.7059597) were divided into 50 intervals of equal lengths (of 0.01754815 and 0.0260839, respectively). The discrete model of market phase space was reconstructed as the ordered set of 2500 distinct cells,
Our approach to reconstructing market phase space is substantially different from the previous works, in which a phase space was discussed as a metaphor of either all possible market events "where the transfer of rights to real estate takes place and decision-making processes occur" , or a collection of recurrence plots containing the information on the systemic trajectory repetition in exchange market times series .
Methods discussed in the present section can be used for a quantitative assessment of the amounts of predictable and unpredictable information in any stochastic process – whether Markovian or not – whenever an empirical transition matrix between the states observed over a certain time horizon becomes available. The proposed methodology resembles the rigorous numerical scheme for approximating invariant densities of dynamical systems, Ulam’s method , and can be adopted to work with diverse, multimodal data sets.
4.1 Predictability of stock behavior in market phase space
The degree to which a correct prediction of the future value of a company stock or other financial instrument traded on an exchange can be made is an important open question for an intelligent investor. The stock market is prone to the sudden dramatic declines of stock prices driven by panic as much as by underlying economic factors . Although the behavior of stock prices might be highly uncertain, the amount of uncertainty can be quantified, and the relevant degree of predictability can be assessed from publicly available information.
4.1.1 Information content of cells in market phase space
The amount of uncertainty associated to an event is related to the probability distribution of the event. Once the event X has been observed, some amount of uncertainty is removed, and the relevant amount of information is released. A highly uncertain event X, occurring with small probability P(X)≪1, contains more information than frequent events. The information content of the event X occurring with probability P(X) is
measured in bits . The information content of tossing a fair coin where the probabilities of heads and tails are p = 0.5 equals −log2 0.5 = 1 bit.
4.1.2 T-days mutual information between cells in market phase space
Mutual information measuring the dependence between two random variables had been introduced by Cover and Thomas  as a measure of predictability of stochastic states in time,
4.1.3 T-days precursors for market events
Bayes’ theorem describes the probability of an event, based on prior knowledge of conditions that might be related to the event . Given that a stock is in the phase space elementary cell X, it may be a t-days precursor of that in t days the stock will be in the cell Y with the following probability:
The KL–divergence (6) has the form of relative entropy  that vanishes if and only if the density of the t- day precursors for the event Y in phase space Pt(X|Y) is identical to P(X). This implies that observation of stock in X is statistically independent of its observation in Y t days later, i.e. X is not a precursor for Y. Relative entropy was proposed as a measure of predictability in [11, 12], and we consider the relative entropy (6) as a measure of predictability for the forthcoming event Y t days ahead.
If the discussed process was Markovian, the marginal probability P(X) is the major eigenvector of the transition matrix
the total information content of the chain. Markovian processes are characterized by the maximum degree of predictability.
4.2 Predictable and unpredictable information estimated from an empirical transition matrix
The empirical transition probability
For example, tossing a unfair coin, in which each state (’heads’ or ’tails’) repeats itself with the probability
0 ≤ p ≤ 1, is described by the Markov chain with the transition probabilities
between ’heads’ and ’tail’ reveals a single bit of information as quantified by Shannon’s entropy,
The information associated to the downward causation process,
quantifies the amount of uncertainty that is released from observation of the sequence of past states of the chain. When p = 0 or p = 1, the series is stationary, and the forthcoming state is determined by observing the past states, so that
Although our capability to predict the forthcoming state by observing the historical sequences weakens as p > 0 or p < 1, we can now guess the future state of the chain directly from the presently observed symbol (by alternating / repeating the current symbol with the probability p > 0, or p < 1, respectively). The related information component (’upward causation’) quantifying the goodness of such a guess is the mutual information between the present and future states of the chain conditioned on the past ,
Our capability to predict the future symbol from the present alone (as quantified by the mutual information (10)) increases as p > 0 (p < 1) till p ≈ 0.121 (p ≈ 0.879) when the effect of destructive interference between the obviously incompatible guesses on alternating the current symbol at the next step (for p > 0) and on repeating the current symbol (for p < 1) causes the attenuation and complete cancellation of this information component in the case of fair coin tossing
The remaining conditional entropy,
Since all information shared between the past and future states in Markov chains goes only through the present, the mutual information between the past states of the chain and its future states conditioned on the present moment is always trivial: I(Xt−1;Xt+1|Xt) = 0 [13, 14].
We can gain insight into predictability and the related amounts of predictable and unpredictable information in the market events and daily stock prices of individual companies by analyzing the empirical t-days transition matrices
5.1 Visualizing the stock market crashes, rallies, and market tumbling on shocking events
The state of the US economy can be visualized by daily snapshots of the S&P 500 stocks in phase space as displayed in Fig. 3. Standard & Poor’s calculates the market capitalization weights (currently ranging from 0.00753 for the National Weather Service to 3.963351 for the Apple company) using the number of shares available for public trading. Movements in the prices of stocks with higher market capitalization (the share price times the number of shares outstanding) had a greater impact on the value of the index than do companies with smaller market caps. In Fig. 3, we indicate the capitalization weights of companies by the radii of circles and jet-colors for convenience of the reader.
Market crashes reveal themselves as a dramatic decline of stock prices across the market when the most of stocks appear in the ’red zone’ of phase space (Fig. 3.a) characterized by the negative return and often negative roughness values, resulting in a significant loss of paper wealth. During the periods of sustained increases in the prices of stocks (i.e., market rallies), the stocks overwhelmingly move to the ’green zone’ of phase space, with positive returns and often positive roughness (Fig. 3.b).
Market tumbling on shocking events constitutes a 2-day synchronization phenomenon (Fig. 3.c & e; d & f). On the first day, many stocks across the market get synchronized on the zero–return value that becomes visible as a vertical line emerging on the phase space snapshots (Fig. 3.c & d). On the second day, the stock market would become essentially volatile, plunging and snapping back due to coherent sells-off / ramping of stocks that might be affected by the announced news. Indeed, the stock drops may result in the rise of stock prices for corporations competing against the affected corporations. Interestingly, a certain degree of coherence in the apparently volatile market movements might persist for a day as it seen from the continued alignment of stocks in phase space visible on the second day of the market recovery process (Fig. 3.e & f).
The first tumbling event shown on Fig. 3.c& e had occurred on Thursday, 07/18/2014, when a Malaysia Airlines plane (flight MH17) headed from Amsterdam to Kuala Lumpur carrying 298 passengers had been shot down by a Russian military unit invading eastern Ukraine. The second tumbling is observed on August 4,2014 (see Fig. 3. d & f) at the coincidence of alarming events, including Argentina’s default on bond payments, more sanctions against Russia backed by EU and US in response to the downing of flight MH17, and the Islamic State seizure of fifth Iraqi oil field. Within that week, the S&P 500 lost 2.69%, the Dow fell 2.75%, and the Nasdaq slid 2.18%.
5.2 Phase portrait , t–days predictability of states, and t–days mutual information in S&P 500 phase space
Not all cells in market phase space are visited equally often by stock prices. The central region, about the zero-return zero-roughness equilibrium point was the most visited of all (see Fig. 4.a) during five years of
observations. This observation is in line with the Mean reversion theory suggesting that asset prices and returns eventually return back to the long-run mean or average of the entire data set . Consequently, the information content is minimal for the frequently visited cells located in the central region, but is high for the periphery cells rarely visited by stocks (Fig. 4.b). The phase space cells corresponding to market crushes are characterized by the maximum information content. Uneven attendance of cells in S&P 500 phase space results in the inequitable degree of predictability of the corresponding events.
The predictability of states calculated as the KL–divergence (6) between the density of t- days precursors for an event and the marginal density of states P(X) across phase space changes with time (see Fig. 4.c & d). Summarizing on short-range predictions based on observation of all possible 1–day precursors for every cell in phase space, we obtain (see Fig. 4.c) that the most predictable states are aligned along the ’main diagonal’ (R ∝ Ṙ) of the phase portrait in S&P 500 phase space, roughly corresponding to the exponential growth (decay) processes with a single unstable equilibrium at the zero-return zero-roughness point (0,0). The states out of the ’main diagonal’ shown in Fig. 4.c cannot be predicted efficiently.
Long-range forecasts predicting the behavior of stocks for more than 3 days in advance follow the different predictability pattern shown in Fig. 4.d. The efficiently predictable states for long-range forecasts are located overwhelmingly in the central region of the phase portrait, about the zero-return zero-roughness unstable equilibrium point. In Fig. 4.d, we have presented the predictability pattern based on 24-day precursors. This observation also supports the general wisdom of the Mean reversion theory . Long-range predictions of infrequent events (such as market crushes) situated on the periphery of the phase diagram should be seen as a rough guide, as the accuracy of such predictions falls considerably around the few days mark.
The decay rate of time-dependent mutual information is an important characteristic of the fluctuations of information flow in a complex system . In the case of small fluctuations of information flow, the time–dependent mutual information decays linearly in time; but the decay might be slower than linear, in the case of the large fluctuations of the information flow in the system . Mutual information decays monotonically with time for Markov processes . In formal languages, the mutual information between two symbols, as a function of the number of symbols between the two, decays exponentially in any probabilistic regular grammar, but can decay like a power law for a context-free grammar .
It is worth mentioning that the time decay of mutual information in time (4) calculated over S&P 500 phase space is very heterogeneous and even non-monotonous. The value of mutual information plunges within the first three days to approximately 7 Kbits and then gets stuck there, at least up to 100-day’s mark (see fig. 5). The observed non-monotonous decay of mutual information may indicate the presence of the long-lasting large fluctuations of information flow that might be attributed to stock market bubbles resulted from groupthink and herd behavior .
5.3 Predictable and unpredictable information in company stock prices. Stocks of different mobility
An intelligent investor is interested in diversification of the portfolio across stocks to reduce the amount of unsystematic risk of each security. Unsystematic risk (related to the occurrence of desirable events) might be associated to the high shares of unpredictable (ephemeral) information in daily stock prices. To quantify the risk levels in market phase space, we have investigated the shares of predictable and unpredictable information in the transitions of stocks between the cells in phase space for all 468 studied companies from the S&P 500 (Fig. 6).
Below, we report the results obtained for 1-day transitions of company stock prices, planning the detailed report on the long-term transitions for the future publications.
We have analyzed the empirical 1-day transition matrices for the stocks of individual companies from the S&P 500 list observed in the last five years. Every transition matrix gives us three values (D,U,E) quantifying the predictable and unpredictable information components in uncertainty of a stock state with respect to one-day transitions. In Sec.4.2, we discussed that the transition matrices for unfair coin tossing can be parameterized by the state repetition probability, so that for every value of 0 ≤ p ≤ 1, we get a triplet (D,U,E)(p) shown in Fig. 2. While working with the S&P 500 data, we have parameterized the (D,U,E) – triplets by uncertainty of daily stock price assessed by its Shannon entropy H producing the curves shown in Fig. 7.
The functional analogy between the state repetition probability 0 ≤ p ≤ 1 for tossing an unfair coin and uncertainty of daily stock price of a company can be intuitively understood in terms of stock “mobility” in phase space. The abundance of trajectory patterns pertinent to highly mobile stocks provide more valuable information for the efficient prediction of the future states. On the contrary, from the forecasting perspective, the behavior of low mobile stocks is prone to high unsystematic risk of unpredictable events like tossing a fair coin.
The empirically observed relations shown in Fig. 6 demonstrate that the amount of predictable information in daily transition of stocks
Although entropy is commonly associated with the amount of disorder, or chaos in a system, our conclusion does not appear as a paradox judged from the everyday perspective. Stocks have different ’mobility’ in phase space as quantified by inequitable uncertainty of daily return (Shannon’s entropy) H in market phase space. In statistics, entropy is related to the abundance of ’microscopic configurations’ (i.e, trajectories of stocks updated daily) that are consistent with the observed ’macroscopic quantities’ (i.e., the density of cells obtained over the whole period of observation) . Highly mobile stocks increase the degree to which the probability of visiting a cell is spread out over different possible trajectories in market phase space, providing more data valuable for the efficient forecasting the future states; the more such trajectories are available to the stock with appreciable probability, the greater it’s entropy. On the contrary, stocks of low mobility characterized by the low levels of Shannon’s entropy do not accumulate enough data for an efficient predictions of the future states.
The shares of information components in complex systems are naturally related to each other. The amount of unpredictable information decreases when the amount of predictable information increases; information predictable from the present state of a system alone is minimum when the future state can be determined from observation of the historic data.
Interestingly, there are remarkable similarities between the information relations observed across the S&P 500 stock market and in unfair coin tossing Fig. (2.a) discussed by us in Sec. 4.2. In Fig. 8.a.) and b.), we have presented the relations between the amounts of unpredictable
Following the analogy between the behavior of stock in S&P 500 phase space and tossing a unfair coin, we may say that stocks highly mobile in phase space characterized by the high entropy values correspond to the
6 Discussion and Conclusion
We have reconstructed the discrete model of S&P 500 phase space and studied predictability of the cells and individual S&P 500 constituents. The certain distributions and coherent movements of points in phase space are associated to the particular states of the market.
Inhomogeneous density of states in S&P 500 phase space results in their inequitable predictability: more frequent market events are predicted more efficiently than relatively rare events, especially in the long-run. The heterogeneous and even non-monotonous decay of mutual information in time might be attributed to strong fluctuation of information flow across S&P 500 phase space arisen due to stock market bubbles.
Mobility of a stock in phase space can be quantified by entropy measuring uncertainty of the daily return of the company. Highly mobile stocks characterized by the high entropy values provide more data valuable for the efficient forecasting the future states and therefore are associated to lower unsystematic risk than the stocks of ’low mobility’. High stock mobility is usually irrelevant to the market capitalization weight of the company. WEC Energy Group Inc., providing electricity and natural gas to 4.4 mln customers across four states through its brands, is characterized by the highest value of entropy (HWEC = 8.377 bit) among all S&P 500 constituents. Entergy Corporation, an integrated energy company engaged in electric power production and retail electric distribution operations, and the CMS Energy Corporation share the second and third places with HWEC = 8.352 bit and HCMS = 8.279 bit, respectively. For comparison with Apple Inc, the leader of the S&P 500 market capitalization weight (3.963351), it’s on the 120th place with HAAPL = 7.5526 bit.
We confirm a great deal of wisdom shared with the common investors by Benjamin Graham in his famous book . Reliable long-range predictions of rare events, such as market crushes, are hardly possible. Companies that offer a large margin of safety are not always those of the highest S&P 500 market capitalization weight. In the last five years, the companies of low unsystematic risk are found in the energy industry, forming the bedrock of our society.
We believe that our work would help to resolve a logical paradox related to EMH on that if no investor had any clear advantage over another, would there be investors who have consistently beat the market, such as Benjamin Graham and his disciple, Warren Buffett?
VS is grateful to the Department of Mathematics and Statistics, Texas Tech University for the support during Summer semesters 2018.
Graham B. (1949 1954 1959 1965) The Intelligent Investor by by Harper & Row Publishers Inc New York.
Radzewicz A. (2013) "Real estate market system theory approach phase space" Real Estate Management and Valuation vol. 21 no. 4 pp. 87-95.
Can-Zhong Yao Qing-Wen Lin (2017). "Recurrence plots analysis of the CNY exchange markets based on phase space reconstruction". The North American Journal of Economics and Finance Vol. 42 Pages 584-596.
Ulam S. M. (1964) Problems in Modern Mathematics New York: Interscience.
Galbraith J. (1988 edition) The Great Crash 1929 Houghton Mifflin Co. Boston.
Han Te Sun Kobayashi Kingo (2002). Mathematics of Information and Coding American Mathematical Society.
Cover T. M. Thomas J. A. (1991). Elements of Information Theory Wiley 576 pp.
Lee P. M. (2012). Bayesian Statistics Wiley. ISBN 978-1-1183-3257-3.
DelSole T. (2004). "Predictability and Information Theory. Part I: Measures of Predictability". J. Atmos. Sci 61 2425–2440.
Kleeman R. (2002). "Measuring dynamical prediction utility using relative entropy". J. Atmos. Sci 59 2057 – 2072.
Volchenkov D. (2018). "Grammar Of Complexity: From Mathematics to a Sustainable World" in World Scientific Series "Nonlinear Physical Science".
James R.G. Ellison Ch.J. and Crutchfield J.P. (2011) Anatomy of a bit: Information in a time series observation Chaos 21 037109.
Mahdavi Damghani B. (2013). "The Non-Misleading Value of Inferred Correlation: An Introduction to the Cointelation Model". Wilmott 2013 (1): 50-61.
KanekoK. Tsuda I. (2011) Complex Systems: Chaos and Beyond: A Constructive Approach with Applications Springer Series in Science& Business Media .
Smith V.L. Suchanek G.L.Williams A.W. (1988) "Bubbles Crashes and Endogenous Expectations in Experimental Spot Asset Markets". Econometrica The Econometric Society. 56 (5): 1119-1151.
Sethna J.P. (2006). Statistical mechanics : entropy order parameters and complexity Oxford: Oxford University Press.