try something like this this, assuming I understand correctly Condition3 = valuewhen(Condition1,BarsSince(Cond3) >25); Signal = Cond1 and Condition2 and Condition3;
-- Cheers Graham Kav AFL Writing Service http://www.aflwriting.com On 05/09/07, professor77747 <[EMAIL PROTECTED]> wrote: > I would like to get an alert when the stochk is going up and was below > 25 within a specified number of bars, but only if the stochk hasn't > been over 75 since it was below 25. I have tried the idea below, but I > know that it doesn't work because Cond3 could have happened before the > stochk was below 25. > > Condition1 = StochK() < 25; > Cond1=StochK() > Ref(StochK(),-1); > Condition2 = BarsSince(Condition1) <=25; > Cond3=StochK() > 75; > Condition3 = BarsSince(Cond3) >25; > > Is this possible? > > Basically, I would like an alert when the stochk is rising up from > below 25 after it has dropped from over 75. I don't care how long as > long as it wasn't over a month ago. > > Thanks, > Tom >
