Hi ,
I have custom indicator which is working fine and DLL also is there but the same is not able to use through strategy builder. Can you please help me how to use to create custom strategy :
public partial class Indicator : NinjaTrader.Gui.NinjaScript.IndicatorRenderBase
{
private VOLAREIndicators.Volare_SuperTrendNewV2[] cacheVolare_SuperTrendNewV2;
public VOLAREIndicators.Volare_SuperTrendNewV2 Volare_SuperTrendNewV2(BarsPeriodType _barsPeriodType, int _barsPeriod, int period, int factor)
{
return Volare_SuperTrendNewV2(Input, _barsPeriodType, _barsPeriod, period, factor);
}
public VOLAREIndicators.Volare_SuperTrendNewV2 Volare_SuperTrendNewV2(ISeries<double> input, BarsPeriodType _barsPeriodType, int _barsPeriod, int period, int factor)
{
if (cacheVolare_SuperTrendNewV2 != null)
for (int idx = 0; idx < cacheVolare_SuperTrendNewV2.Length; idx++)
if (cacheVolare_SuperTrendNewV2[idx] != null && cacheVolare_SuperTrendNewV2[idx]._BarsPeriodType == _barsPeriodType && cacheVolare_SuperTrendNewV2[idx]._barsPeriod == _barsPeriod && cacheVolare_SuperTrendNewV2[idx].Period == period && cacheVolare_SuperTrendNewV2[idx].Factor == factor && cacheVolare_SuperTrendNewV2[idx].EqualsInput(input))
return cacheVolare_SuperTrendNewV2[idx];
return CacheIndicator<VOLAREIndicators.Volare_SuperTrendN ewV2>(new VOLAREIndicators.Volare_SuperTrendNewV2(){ _BarsPeriodType = _barsPeriodType, _barsPeriod = _barsPeriod, Period = period, Factor = factor }, input, ref cacheVolare_SuperTrendNewV2);
}
Comment