RainbowOscillator


Summary

The Rainbow Oscillator is a process of repetitive smoothing of simple moving averages resulting in a full spectrum of trends.

Syntax

public RainbowOscillator RainbowOscillator(DataSeries source, int levels, MovingAverageType maType)

Parameters

NameDescription

Example 1

//...
private RainbowOscillator rainbow;
protected override void Initialize()
{
    MovingAverageType simpleMa = MovingAverageType.Simple;
    DataSeries close = MarketSeries.Close;
    rainbow = Indicators.RainbowOscillator(close, 9, simpleMa);
    //...
}
public override void Calculate(int index)
{
    double currentValue = rainbow.Result[index];
    //...
}