Showing posts with label Log Preiodic Power Law. Show all posts
Showing posts with label Log Preiodic Power Law. Show all posts

Thursday, September 3, 2009

World stock market: approaching trend reversal?

Another interesting implementation of LPPL model has been just published today. Stanislaw Drozdz and Pawel Oswiencimka in short paper predict that core stocks indexes will face significant correction. A quote:

Based on our ”finance-prediction-oriented” methodology which involves such elements as log-periodic self-similarity, the universal preferred scaling factor 2, and allows a phenomenon of the ”super-bubble” we analyze the 2009 world stock market (here represented by the S&P500, Hang Seng and WIG) development. We identify elements that indicate the third decade of September 2009 as a time limit for the present bull market phase which is thus to be followed by a significant correction

Read More......

Sugar bubble ready to burst

Over the past few weeks, sugar has been on such upward spiral, hitting a 28-year high. Growing demand in Brazil for sugar to be turned into ethanol, coupled with a sharp fall in Indian and Brazilian production, have both sent sugar prices sky high. Many think that the supply shortfall will extend through 2010. Then from fundamental perspective valuation current sugar valuation may be correct as the supply fall short behind the demand. But to speak of supply and demand as if they were determined by forces that are independent of the market participant’s expectations is quite misleading.

It’s true the situation is not so clear cut in case of commodities where supply is largely dependent on production and demand on consumption. But the price that determines the amounts produced and consumed is not necessarily the present price. On the contrary, the market participants are more likely to be guided by future prices, either as expressed in future markets or as anticipated by themselves. In either case it is inappropriate to speak of independently given supply and demand curves because both curves incorporate expectations about future prices.

Those expectations may become self-referential which will lead to the positive feedback process (the higher the price or the price return in the recent past, the higher will be the price growth in the future). Positive feedbacks, when unchecked, can produce runaways which beyond a certain point become unsustainable ending in crash. In short LPPL models developed by Sornette aims, at detecting the transient phases where positive feedbacks operating on some markets or asset classes create local unsustainable price run-ups. The result of the analysis is summarized bellow in figure 1.



I analyzed sugar#11 future time series between September 2007 and September 3 2009. The y axis is logarithmically scaled so that the exponential function would appear as a straight line. LPPL fit exhibit upward curvature which is clear evidence that the prices were growing “super-exponentially”. The projected crash dates are September 5-15 .It must be noted that a good fit of the model to the data series is not a 100% certainty for a crash, but it clearly points at a bubble formation.

Read More......

Friday, July 3, 2009

S&P 500 - critical time

It is fair to say that the global economic system is one of the most complex systems known in the biosphere. Compared to physics, economics differs in the important fact that the basic constituents, or “particles”, are already quite complex: human beings. So macroeconomic knowledge is insufficient tool to predict market trends as not only hard data are important but also how human beings think about macroeconomic reality.

John Maynard Keynes made a famous observation that much of individual economic behavior is due to “animal spirits” rather than long-term rational calculus so beloved by economic theorists and fundamental analysts.

That’s why I don’t want here to discus macroeconomic picture (i.e most recent US job readings) because it’s rather trivial task as we are still in negative feedback process (i.e. banks continue to tighten credit standards –> less credit available means lower demand -> lower demand means higher unemployment -> higher unemployment undermines creditworthiness -> banks continue to tighten credit standards etc)

What I would like to focus here on fact that series generated by some complex systems (i.e. financial markets ) are characterized by periodic or nearly periodic behavior. In these cases, the dynamics can be characterized by scaling laws. Such dynamics are usually denoted as fractal or multifractal, depending on the question if they are characterized by one scaling exponent or by a multitude of scaling exponents. Sierpinski gasket is one fine example of fractal




Some times its necessary to conduct series of tests to find the scaling factor but in case of S&P 500 the self similar pattern is clear at the first glance.





I simply repeat the analysis which I done last year and I got very similar scaling factor 2.7. In words it may indicate that S&P 500 is around critical time and that in August we may test the March lows.

Read More......

Friday, June 26, 2009

Irrational Exuberance. LPPL signatures in EUR/PLN



People like to go to excesses. I think that what started out with a tulip, maybe four-hundred years ago, and continued through the South sea bubble and all of those sorts of things ( Tronic bubble in 60’s, new economy bubble in 90’s). I’m not saying here that that all human choices are orthogonal to rational ones but in human nature is to heard. Herding can result from a variety of mechanisms, such as anticipation by rational investors of noise traders strategies, agency costs and monetary incentives given to competing fund managers, sometimes leading to the extreme Ponzi schemes, rational imitation in the presence of uncertainty, and social imitation. Many financial economists recognize that positive feedbacks and in particular herding is a key factor that can push prices upward (downward) faster-than-exponentially which if unchecked can lead to bubbles.

Roughly 10 years ago Johansen and Sornette proposed model that attempts to incorporate those ingredients into a traditional rational expectations model of bubbles proposed by Blanchard.

The Jochansen-Sornette model assumes the financial market is composed of two types of investors: perfectly rational investors who have rational expectations and irrational traders who are prone to exhibit herding behavior. The noise traders drive the crash hazard rate according to their collective herding behavior, leading its critical behavior. Due to the no-arbitrage condition, this is translated into a price dynamics exhibiting super-exponential acceleration, with possible additional so-called “log-periodic” oscillations associated with a hierarchical organization and dynamics of noise traders.

A+B*(t-tc)^C*(1+D*COS(w*LN(t-tc)+O)

This so-called log-periodic power law (LPPL) dynamics given by has been previously proposed in different forms in various papers. The power law A−B(t−tc)_ expresses the super-exponential acceleration of prices due to positive feedback mechanisms. The term proportional to cos(w ln(t-tc)+o) describes a correction to this super-exponential behavior, which has the symmetry of discrete scale invariance. This formulation results from analogies with critical phase transitions (or bifurcations) occurring in complex adaptive systems with many interacting agents. The key insight is that spontaneous patterns of organization between investors emerge from repetitive interactions at the micro-level, possibly catalyzed by top-down feedbacks provided for instance by the media and macro-economic readings, which are translated into observable bubble regimes and crashes.

In previous posts I fit the LPPL formula into several financial time series. This time I fit LPPL into EUR/PLN exchange rate. As it is seen on the chart the formula fits remarkably well into the data. Even more surprisingly the LPPL model explains not only the periods when the positive feedbacks let to the zloty overvaluation but also it fits well to the period when zloty was depreciating (2001-2003). This confirms the universality of the process described by LPPL formula which describes well not only bubbles but also antibubbles.

Read More......

Monday, September 1, 2008

In October S&P 500 index is likely to retest recent lows

This post is an update to the S&P500 prediction posted on this blog earlier in July. The prediction comes true as well as oil bubble burst forecast issued here. However the S&P index did not plunge as low as 1150 points but the critical time prediction was quite accurate. Also it has to be remembered that critical time obtained from LPPL models is only the most probable point of trend reversal. Financial markets are complex and open systems and its valuation oscillations are driven both by endogenous end exogenous factors. In July In my assessment S&P500 price dynamics was strongly affected by SEC naked short-selling ban on the stocks of major financial institution. But take me correct I don’t think that SEC decision was wrong on contrary I think it was absolutely correct and needed as it break negative feedback loop.



Here I want to make an update to my earlier prediction of S&P500 based on LPPL model. An LPPL model applies concepts of criticality from statistical physics however I will not focus here on the theory complex systems (nice and easy to read easy on complex system and LPPL models you can find here .)

A complex system is a system composed of interconnected parts that as a whole exhibit one or more properties (behavior among the possible properties) not obvious from the properties of the individual parts. Financial markets and economy as a whole is a complex system buildup with a large number of interconnected elements.

The characterization and understanding of complex systems is a difficult task, since they cannot be split into simpler subsystems without tampering the dynamical properties.
One approach in studying such systems is the recording of long time series of several selected variables (observables), which reflect the state of the system in a dimensionally reduced representation

Data series generated by complex systems exhibit fluctuations on a wide range of time scales and/or broad distributions of the values. Some systems are characterized by periodic or nearly periodic behavior. In these cases, the dynamics can be characterized by scaling laws. Such dynamics are usually denoted as fractal or multifractal, depending on the question if they are characterized by one scaling exponent or by a multitude of scaling exponents.

If one finds that a complex system is characterized by fractal dynamics with particular scaling exponents, this finding will help in obtaining predictions of the future behavior of the system.
In 2000-2003 anti-bubble/bear phase The S&P500 index shows clear oscillations with 5 sharp local minima and the self similar structure and the scaling exponent was easy to find.









The local minima are dated as follows: m5=12-Oct-2000; m4=20-Dec-2000; m3=04-APR-2001; m2=21-SEP-2001; m1=23-July-2002.

Log-Periodicity means that that the ratios of the distances between the consecutive repeatable minima should be constant equal to the preferable scaling ratio λ which is a signature of Discrete Invariance Scale(DSI)

(Mn-Mn+1)/(Mn+1-Mn+2)=(Mn+1-Mn+2)/(Mn+2-Mn+3)=λ
Using the previously determined minima M1,…,M5 we get

(m1-m2)/(m2-m3)=λ1=1.79
(m2-m3)/(m3-m4)=λ2=1.62
(m3-m4)/(m4-m5)=λ3=1.52


It shows that all scaling ratios are comparable and if it would be known ex-ante it would help to find next local minima in the bearish trend giving significant upper hand. More detailed discussion about 2000-2003 S&P500 index anti-bubble period you can find in D.Sornete works (link here 1 2 3)

The main disadvantage of the Shrank’s transform presented above it that it needs quite a long time series to determine the preferable scaling factor of the system. Although in the current bearish pattern of the S&P 500 index also shows strong oscillations but the time series is much shorter and its much harder to determine the scaling parameters. So instead of Shrank’s transform I implemented the Lomb spectral analysis. I done the computation in Matlab using procedure written by Brett Sholeson. After visual analysis of the S&P500 index I chose for critical time tc=10-10-2007, then the data was detrended.



The Lomb periodogram (chart 2) exhibit an extremely significant peak close to log-frequency f=w/2π=2.6 with the amplitude larger than 60. Second peak is close to 2w log frequency which suggest the presence of harmonic anagular. The visual structure of the current S&P500 time series with double minima pattern also suggest suggest the presence of a rather strong harmonic at the angular logfrequency.

The data fit quite well to the formula. Numbers on horizontal are counting the distance in trading days from the critical time tc=10-10-2007
Below I put the chart with the forecast for S&P 500 index from the LPPL model. The forecast suggest that the next minima S&P500 index will reach in October/November and the index should rally into year 2009 when the trend should turnaround toward new minma.






Read More......

Monday, June 16, 2008

US equity markets are in negative feedback loop – in July S&P 500 is likely to plunge to 1150points


The current financial crises will have more serve and longer lasting-consequences than similar crises in the past. Credit contraction which is highly correlated with real economy cycle may be prolonged as the

1) FED ability to keep interest rates low may be limited

2) some mayor financial institution may prove yet to be insolvent


3) The banking sector regulation liberalization process is over as tax payers funds were involved to bail out troubled financial sector . Now regulators are likely to tighten control over the investment banking activities which could dampen further dampen credit expansion.


But this is not my main argument for steep market correction in the near term. To be correctly understood I’m not calling for master of disaster global scenario because there are countervailing forces at work. China, India and Oil producing countries economic growth remains strong. More importantly emerging markets governments have continued to acquire US assets even as the US yields has fallen which may be support for Bretton Woods II believers (here you can read the newest David Folkerts-Landau paper on Bretton Woods II and subprime crises)


My judgment on US equity market is based on macroeconomic logic and the Log Periodic Power Law (LPPL) developed by D.Sornette in series of articles. Based on models of imitation between traders and cooperative heading behavior Sornette showed that imitation leads in finite time to very large market highs followed by the crash.

In later papers it was realized that speculation and imitation also occur during bearish markets, leading to price trajectories that seem approximately symmetric to the accelerating speculative bubbles ending in crashes. “antibubbles” are characterized with a power law decrease of the price decelerating log periodic oscillations.


Anti-bubbles concept has been successfully implemented to Nikkei, S&P and gold markets descents (papers are available here S&P , Nikkei & Gold , Chinese equities& real estate )


I implemented Sornette methodology to the present S&P 500 data and I got very stable firt for first and second order log periodic oscillations. Lomb spectral analysis showed very strong log periodic oscillations amid descending trend.


The best fit with second order Landau Formula suggest that next local minimum S&P 500 index will reach close to the end of July 2008 when the index is likely to fall as low as 1150 points.

Read More......

Saturday, June 7, 2008

OIL - emerging BUBBLE


Last Thursday Brat Stupak chairman of Congressional energy panel said that oil products markets were being “manipulated” by the biggest trading houses in the futures market, through he said a probe hasn’t uncover illegal activity.

I must say that I don’t understand what congressmen Stupak wanted to communicate by his comment.
Earlier this week Gerorge Soros testified before US congressional committee on manipulation in the energy markets . He said the record oil prices weighing on the economy are the result of a ``bubble'' caused by speculation from index funds and a tight balance between supply and demand. Few days earlier in the interview for Daily Telegraph Mr Soros highlighted 4 main factors behind soaring oil prices
1) Peak oil – Meaning increasing costs of developing new oil reserves and aging of the existing oil fields
2) The backward sloping oil supply curve –the higher the oil price goes the less incentive oil producing countries has to convert their oil reserves into depreciating currencies (mainly US dollars). In other words the OPEC grew richer and less in need of current income, while negative real interest rates made it more attractive to keep oil in the ground than cash it at bank
3) The mayor of growing areas of growing demand subsidizes the energy prices so the higher oil prices does not affect oil consumption in those areas.
4) Trend following speculation which possibly will end up with the bubble.
I think his analysis is correct and the 4th factor is increasingly affecting the oil prices. Let’s start with the definition of the bubble
The term “bubble” is widely used but rarely clearly defined. Following investopedia “bubble” is defined as
“A spike in asset values within a particular industry, commodity, or asset class. A speculative bubble is usually caused by exaggerated expectations of future growth, price appreciation, or other events that could cause an increase in asset values. This drives trading volumes higher, and as more investors rally around the heightened expectation, buyers outnumber sellers, pushing prices beyond what an objective analysis of intrinsic value would suggest.”
This definition as all others contain flaw. Indeed defining bubble is very tricky because acceptance or rejection of the bubble is depends on the model of fundamentals one uses. The concept of a fundamental price reference does not necessarily exist, nor is it necessarily unique. A major problem is that apparent evidence for bubbles can be reinterpreted in terms of market fundamentals that are unobserved by the researcher A key problem is that bubbles are usually defined as exponentially explosive growth phases, but how can one then distinguish them from the growth of a fundamental valuation process which is also generically expected to follow an exponential growth path?
This problem can be solved by defining a bubble as a faster-than-exponential accelerating price, which may be refed to as “superexponential.” Being faster than exponential, i.e., the growth rate is itself growing; it is necessarily unsustainable if we assume a standard geometric growth for the global economy. Why then the prices start to grow at unsustainable “superexponential” rate? Soros explain it by his reflexivity theory which says that market participants are trying to discount a future that is itself shaped by market expectations. This is self reinforcing “rational” process which is a seed for rational bubble.
In recent years prof. Didier Sornette developed a new methodology to test fingerprints of speculative bubbles called Log Periodic Power Law (LPPL). In a series of works, financial bubbles have been defined as regimes in which the market exhibits an unsustainable super-exponential growth, that can be characterized quantitatively as a genuine critical phenomenon with specific log-periodic power-law signatures. The main ingredient of the theory is the existence of positive feedbacks, that is, self-reinforcements, which leads to cooperative herding and imitation between investors. As a consequence, the actions of investors tend to produce waves of contrariant and imitative behaviors leading to self-reinforcing bullish or bearish phases, themselves decorated by the opposite regimes in a hierarchical fashion. Positive feedbacks, when unchecked, can produce runaways until the deviation from the fundamental price is so large that other effects can be abruptly triggered and lead to rupture or crashes. Alternatively, it can lead to prolonged depressive bearish markets
Mathematically, the LPPL model is represented by the equation giving the anticipated expected trajectory of the log-price I(t) ≡ ln p(t) of a given asset as a function of time, expressed in terms of the distance τ = tc − t (respectively τ = t − tc) to the critical time tc for bubbles:
I (t) = A + Bτ^α + Cτ^α cos [ω ln (τ )]
A is the log-price at tc (since τ = 0 at t = tc, all the other terms are vanishing at t = tc), B (respectively) controls the amplitude of the power law acceleration (respectively the log-periodic component) of the log-price. The exponent α encodes the structural shape of the acceleration. It is usually found between 0 and 1, which ensures a finite price at tc together with an asymptotic infinite rate of change close to tc. The parameter ω is the log-periodic angular frequency of the log-periodic oscillations. It should be stressed that ω is not the inverse of a time scale, but rather it is proportional to the inverse of the logarithm of a scale factor λ, where λ is roughly speaking the ratio of the distances between successive peaks of the log periodic oscillations.
LPPL formula (chart) when fitted to the oil data shows 1) very low alfas which confirms acceleration of the underlying trend 2) superexponential growth is accompanied with stable log periodic oscillations which confirms an existence of positive speculative price to price feedback. This is an initial confirmation that oil price incresingly depends on speculation
The initial estimation suggest that oil price within next two weeks will spike to around 150 dollars per bbl.

Read More......