I'm not sure what you are refering to, but what if you used conditions? for example:
condition1 = close[3] > highest(high,10)[3];
condition2 = close > close[1];
if condition1 and condition2 then buy this bar at close;
This way you access past bars and if your various conditions aren't met then there is no signal.
Good luck - though I would change forums to get better answers.