Amazon deals

Friday, May 8, 2009

Why you need to learn about the Stochastic Oscillator

I have been planning to write about the Stochastic oscillator for quite some time. Reader Nikesh deserves special thanks for reminding me about it every once in a while.

In an article last July, identifying stock market trends using exponential moving averages (EMAs) and their crossovers was explained. A problem that one often faces with EMAs is that before they can confirm a change of trend, price levels often rise (or fall) by a significant amount.

I discovered that the Stochastic oscillator worked very well with EMAs to give early buy/sell indications and was very useful for timing entry into (or exit from) individual stocks. There are other indicators that can be used as well. But the stochastic oscillator provides clear and simple visual guidance.

Let us take a look at the 6 months bar chart pattern of Balrampur Chini, a sugar stock which I discussed last Wednesday, to find out the utility of the Stochastic oscillator:-

Balrampur_May0709 

(Please right-click on the image; open it in a new tab or window for a better view.)

The Stochastic oscillator compares the closing price level of a stock (or index) with its price range over a given time period - say 10 days. It comprises two lines - the main '%K' line (in blue) and the '%D' line (in red); the '%D' line is a moving average of the '%K' and acts as a 'signal' line. When the '%K' moves above the '%D', it is considered bullish; when it moves below, it is bearish.

Both the lines 'oscillate' (i.e. alternatively go up and down) between values of 0% and 100%. The zone between 0-20% is considered 'oversold'; the zone between 80-100% is overbought.

(The actual calculations of '%K' and '%D' are slightly complicated, and I don't want to confuse any maths-shy readers unnecessarily. One can use the oscillator without understanding the underlying maths - much like driving a car without any idea of the function of the carburettor. Those who are maths-happy, and love to know the gory details, can email me.)

In Nov '08, Balrampur's stock price was well below the 20 day EMA, which in turn was below the 50 day EMA. The 50 day EMA was significantly below the 200 day EMA and all three EMAs were moving down. The bear grip on the stock was strong.

Look what happened in early Dec '08. The stock had a 'reversal day' (i.e. a lower low at Rs 30 and a higher close) and spurted up on small volumes. The '%K' (blue) line first moved above the '%D' (red) line, and then both lines moved up above the 'oversold' zone. That was a 'buy' signal, much before the stock moved above its 20 day EMA to confirm a 'buy'.

When the stock moved above its 50 day EMA in end-Dec '08, the stochastic oscillator was already in the 'overbought' zone. Before the big market correction came due to the Satyam scam news in Jan '09 (that caused all stocks, including Balrampur, to fall) the stochastic oscillator made an early downward break from the 'overbought' zone.

In Feb '09, the Balrampur stock was making new highs and getting resisted by the 200 day EMA. The stochastic oscillator had a lower high, indicating a negative divergence and a 'sell' signal. A 30% correction followed.

In Mar '09, the stock was consolidating sideways when the stochastic oscillator gave an early 'buy' signal by moving up from the 'oversold' zone. The stock price nearly doubled within a month.

In May '09, the stock made a new high above Rs 80 but the stochastic oscillator made a lower high - again a negative divergence and a 'sell' signal. A price correction should follow.

In the example above the 'slow' stochastic oscillator - that uses a 3 day average of the %K - has been used. I find it more useful than the 'fast' stochastic which tends to fluctuate more, giving false signals.

For timing entry/exit there are few technical indicators that can provide such 'leading' (i.e. early) indications. But I must reiterate that technical indicators work best when several of them are used together to determine trends.

In future posts, I plan to write about two other useful technical indicators - the MACD and the RSI.

2 comments:

Nikesh Goyal said...

I think you must be expecting some comments from me... so i made a comment here ;)


I was a big fan of the such kind of technical analysis such as stoch, MACD, RSI, W%R or such other things..

But now now...
I am not now a big fan of technical analysis now... rather now I hate it...


And the reason.... I think you can check yourself... can you backtest any indicator with NIFTY and get positive results ???

It looks like that stoch, RSI or MACD will solve the problem but they will not solve...

There is only one thing you can do with your investment.... search for undervalued company... keep accumulating on every low and keep selling on every high AND the best approach is keep accumulating in every low and keep it with you until you need that money really hard....

Your opinion on this comments are welcome!

Subhankar said...

Hi Nikesh

I wasn't even sure that you would read this post - so your feedback is an added bonus.:-)

Tech analysis can be quite frustrating some times, specially if you lose money on a technical call.

I agree with you that fundamental research for undervalued stocks is by far the best approach for investors.

However, even carefully selected undervalued stocks can lose further value if you enter at the wrong time. That is where tech. analysis can provide some help.

I don't track the Nifty because the authorities do not consider opening 'gaps'. The previous day's close is treated as the following day's opening level. This makes it unsuitable for my analysis purposes.