I tried to implement a Trend RSI which I want to be a RSI(MACD(23,50,9), 9) and used the Wizard to generate this bugged code :
---
protected override void Initialize()
{
Add(new Plot(Color.Orange, PlotStyle.Line, "STR"));
Rperiod = 9;
Smooth = 9;
Mfast = 23;
Mslow = 50;
CalculateOnBarClose = true;
Overlay = false;
PriceTypeSupported = false;
}
/// <summary>
/// Called on each bar update event (incoming tick)
/// </summary>
protected override void OnBarUpdate()
{
// Use this method for calculating your indicator values. Assign a value to each
// plot below by replacing 'Close[0]' with your own formula.
STR.Set(RSI(MACD(Close, Mfast, Mslow, Smooth) ,Rperiod, Smooth)[0]);
}
---
would you mind lending a hand ?
Comment