/*[[ Name := T3 filter Author := Copyright © 2003, Company Link := http://www.company.com/ Separate Window := yes First Color := Blue First Draw Type := Line First Symbol := 217 Use Second Data := No Second Color := Red Second Draw Type := Line Second Symbol := 218 ]]*/ Input : t6_period(24),hot(0.7),num_bars(2000),Price(PRICE_CLOSE),for_price_open(price_open),advance(0); Variable : shift(0); Variable : t6(0),init(true); Variables : bar(0), prevbars(0), start(0), cs(0), prevcs(0),commodt("eurusd"),frame(0); Variable : e1(0),e2(0),e3(0),e4(0),e5(0),e6(0),c1(0),c2(0),c3(0),c4(0),ep1(0),ep2(0),ep3(0),ep4(0),ep5(0),ep6(0); Variable : n(0),w1(0),w2(0),b(0),b2(0),b3(0); cs= t6_period+hot+Price+advance+num_bars+v; //checksum used to see if parameters have been changed if cs=prevcs and frame=t[4]-t[5] and (commodt=symbol)and bars-prevbars<2 then start=Bars-prevbars //params haven't changed only need to calculate new bar else start=-1; //calculate all bars1 then alert("start: ",start); if (start=1 and shift=1) or start=-1 then { e1=ep1; e2=ep2; e3=ep3; e4=ep4; e5=ep5; e6=ep6; } SetIndexValue(shift+(advance*-1), t6*1000); End;