there is strange code related to ADX indicator like:
[FONT="Courier New"][SIZE="2"]public partial [COLOR="blue"][B]class Strategy[/B][/COLOR] : StrategyBase
{
private NinjaTrader.Indicator.[COLOR="Red"]ADX _indicator[/COLOR] = [COLOR="red"]new NinjaTrader.Indicator.ADX()[/COLOR];
public override bool CalculateOnBarClose
{
get { return base.CalculateOnBarClose; }
set { base.CalculateOnBarClose = [COLOR="red"]_indicator.CalculateOnBarClos[/COLOR]e = value;
}
public override int BarsRequired
{
get { return base.BarsRequired; }
set { base.BarsRequired = [COLOR="red"]_indicator.BarsRequired[/COLOR] = value;
}
}[/SIZE][/FONT]
It looks like this specific indicator needs some special handling.
Why only this one indicator is handled this way?
For any other indicator I have never seen anything similar...


@Strategy.cs is just the base class for all other strategies, and is itself derived from StrategyBase. It is not an indicator.
Comment