All I am doing is creating a BollingerBand Width and plotting the Max/Min of that indicator over x amount of bars, similar to a Donchian Channel.
Here is the code logic. Everything compiles, but it is just plotting 0 for the Max & Min values
else if (State == State.DataLoaded) { max = MAX(Plot0,150); min = MIN(Plot0,150); } } protected override void OnBarUpdate() { if (CurrentBar < Period) { return; } double max0 = max[0]; double min0 = min[0]; Plot0[0] = (Bollinger(Deviation,Period).Upper[0] - Bollinger(Deviation,Period).Lower[0])/Bollinger(Deviation,Period).Middle[0]*100; Upper[0] = max0; Lower[0] = min0; }
Comment