World Finance 100
LiteForex community on Facebook LiteForex community on Twitter LiteForex community on Google+ LiteForex community on Youtube RSS Feed LiteForex community on MQL5

Oscillator class

Our Forex tutorial provides all the information indispensable to successful work in the Forex market

In this class we will review such indicators as StochasticOscillator and DeMarker.

StochasticOscillator is regarded to be one of the most wide-spread indicators and gives way only to MA. This indicator takes into consideration (when calculating) not only closing prices in that or this time interval, but also both maximums and minimums of the prices, that were reached during the same interval. It reflects closing price of the last time interval in relationship to price interval (from maximum to minimum) for n-intervals in the past. StochasticOscillator values are calculated in percents that is why it, as a rule, is built in separate frame with 0 to 100 interval, however, some variations of this indicator permit to build StochasticOscillator directly on the price chart.

According to the idea of creator of this indicator, J. Lane (the president of InvestmentEducatorsInc. corp.) in process of descendant trend formation the closing prices of bars are situated near the lower ground of the diapason (channel). In the contrary, during ascendant trend formation the closing prices stand near the maximum of the diapason (channel). These claims are quiet logical, because in case of descendant tendency the price constantly forms new minimum, and thus the last prices are situated near this minimum. In case of ascendant trend new maximums are formed constantly, and the closing prices respectively are situated near those maximums.

In the illustration you can see that while forming ascendant trend, the last closing prices "crowd" new upper ground of price diapason (channel).

Let us see the formula of formation of this indicator in details. It consists of two lines %K and %D. These names are the result of long research work, when a group of traders tried to find more convenient variant, giving names to new indicators like %A, %B, %c etc. %D (slow stochastics ) and %K (fast stochastics ) came out to be functional. Let us take into consideration n-periods. At this time interval we have a local maximum (it will be denoted as Maxn) and minimum (Minn )  Closing price will be C. 

Then 

%D - it is MA of %K for which, as a rule, very small averaging period is chosen. Moreover method of calculation of this moving average may be different (depending on trader), for example, simple MA, exponential MA etc.

There are following trading signals of this indicator:

  • To buy subject to the line of indicator (%K and %D) will first lower in the oversold area (on default, it is 20%) and then leave it, starting to lift. To sell when the line of indicator (%K and %D) will first lift from the overbought area (on default it is 80%) and then leave it, going down.
  • To buy when crossing %D line with %K bottom-up. To sell crossing %K line with %D line top-down.

Besides, the fact of reaching by the indicator (%K and %D) the overbought area itself can be regarded as a prove of the delaying of price rising tendency in near future, and the reaching the oversold area can be regarded as a signal of delay of price decrease. 

Analytics also track the divergences between maximum and minimum of the price, and corresponding extremums of the indicator (the same way as MACD divergences).

The following illustration show abstract (typical) picture of the readings of StochasticOscillator. 

Picture 16 Construction of StochasticOscillator indicator at an abstract chart

DeMarker. It is the second indicator of this type, that will be reviewed as an example for our course - the indicator of Thomas R. DeMark (the author of the book "New Science of Technical Analysis"). It works to define if the current maximum of the bar could overcome previous maximum. According to the author, he tried to create an indicator without any typical disadvantages of oscillator indicators and that could identify potential extremums (maximums and minimums).

"Inside" of the indicator following happens. In case when current bar maximum is higher than previous one, their difference (delta) is registered. We will denote it as ∆max. If the current maximum did not become higher than previous one, then ∆max. is equal to zero. And vice versa, if the current bar minimum is lower than previous one, then the difference - delta of minimums is calculated (let it be ∆min)

Then the current indicator value is calculated using the formula:

Where SMAn – is a simple MA in n-period.

Picture 17 Construction of DeMarker indicator at an abstract chart

Thus the indicator can take values within 0 and 1. The author singles out 0.3 and 0.7 levels. The overbought of the market takes place when the indicator reaches the area higher than 0.7-point. the oversold zone is lower than 0.3-point. In case of finding the indicator in these areas the delay or change in tendency might be expected. The basic signals of this indicators are: 

  • The selling signal at the moment of quitting the overbought area (i.e. the line crosses the indicator of 0.7 level top-down).
  • The buying signal at the moment of quitting the oversold area (i.e. the line crosses the indicator of 0.3 level bottom-up).

The indicator is built in a separate frame, where you can see trends and patterns of graphic analysis like at the price graph (for example, "head & shoulders", "double top" etc.). The trying of a tendency may also be a separate signal of the indicator. As well as for the other indicators, the divergence with the price may also be tracked by DeMerker.