diff --git a/indicators/RSIDashboard.cs b/indicators/RSIDashboard.cs index cfea99d..6179e34 100644 --- a/indicators/RSIDashboard.cs +++ b/indicators/RSIDashboard.cs @@ -24,8 +24,8 @@ namespace NinjaTrader.NinjaScript.Indicators private Dictionary RSIIndicators = new Dictionary(); - private string[] TimeFrames = new[] { "1 Minute", "5 Minutes", "30 Minutes", "1 Hour", "4 Hours", "Daily", "Weekly" }; - private double[] RSIValues = new double[7]; + private string[] TimeFrames; + private double[] RSIValues; protected override void OnStateChange() { @@ -35,6 +35,8 @@ namespace NinjaTrader.NinjaScript.Indicators Name = "RSI Dashboard"; Calculate = Calculate.OnBarClose; IsOverlay = true; + TimeFrames = new[] { "1 Minute", "5 Minutes", "30 Minutes", "1 Hour", "4 Hours", "Daily", "Weekly" }; + RSIValues = new double[TimeFrames.Length]; RSIPeriod = 14; RSISmoothing = 3; UpperThreshold = 65;