[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Anchoring a barnumber



PureBytes Links

Trading Reference Links

List,

I am having a difficult time in anchoring and keeping as a varible value 
a bar number in an intraday context., at least I think that is the
problem.

I have the following:

If x[1]< y[1] and x > y then buysignal =1 else buysignal =0;
(Should I put an end; here?)

If buysignal =1 then Buy blah blah at next bar market;

{Here is where I want to start setting varible to enable doing some
barnumber arithmetic to calculate highs and lows reletive to the buy
signal.)

If buysignal = 1 then begin
If BuySignal =1 then LongPositionBarNumber = currentbar;
CurBar = currentbar;
xyz varibles..... 

I assume that if buysignal = 1 and there after it is zero then 
I assume that LongpositionBarNumber will remain the same value.
as buysignal stays at zero.

 
Would appreciate any assistance..

Don Thompson.