Universal Oscillator John Ehlers

Category: Indicators By: Nicolas Created: April 21, 2016, 10:03 AM
April 21, 2016, 10:03 AM
Indicators
5 Comments

The Universal Oscillator made by John Ehlers is based on article “Whiter is Brighter” wrote in TASC magazine in January 2015.

This oscillator is an evolution of John Ehlers previous indicator “SuperSmoother filter” which was introduced in his January 2014 article “Pedictive and Succeful indicators”.

This indicator reflects short term variations of price within the “bandedge” parameter as a  frequency. Of course, the lesser this parameter is, the less lag is the oscillator, it is setted at 20 periods by default. Returned values oscillate between -1 and 1.

Basic rules would be to sell short when the curve crosses below 0 and go long when it crosses above 0.

bandedge= 20
whitenoise= (Close - Close[2])/2

if barindex>bandedge then
 // super smoother filter
 a1= Exp(-1.414 * 3.14159 / bandedge)
 b1= 2*a1 * Cos(1.414*180 /bandedge)
 c2= b1
 c3= -a1 * a1
 c1= 1 - c2 - c3
 filt= c1 * (whitenoise + whitenoise[1])/2 + c2*filt[1] + c3*filt[1]

 filt1 = filt

 if ABS(filt1)>pk[1] then
  pk = ABS(filt1)
 else
  pk = 0.991 * pk[1]
 endif

 if pk=0 then
  denom = -1
 else
  denom = pk
 endif

 if denom = -1 then
  result = result[1]
 else
  result = filt1/pk
 endif
endif

RETURN result COLOURED(66,66,255) as "Universal Oscillator", 0 as "0"

 

Download
Filename: Universal-Oscillator-J.Ehlers.itf
Downloads: 308
Nicolas Master
I created ProRealCode because I believe in the power of shared knowledge. I spend my time coding new tools and helping members solve complex problems. If you are stuck on a code or need a fresh perspective on a strategy, I am always willing to help. Welcome to the community!
Author’s Profile

Comments

Logo Logo
Loading...