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

Re: Can MS do loops?



PureBytes Links

Trading Reference Links

Mullin285@xxxxxxx writes:

> Thanks for popping in. Basically I am trying to learn how to use MS but the
> thing that triggered this particular question was ... I wanted to close my
> long trades if there were 3 consecutive down days. I tried : C<prev and
> C<prev-1 and C<prev-2 but that didn't work out right Seemed to be acting
> more like I said or instead of and.

In this *particular* case, you probably want:

C < Ref(C, -1) and Ref(C, -1) < Ref(C, -2)

As I understand it, "PREV" refers to the value of the *entire* formula; not
just the 'last thing it saw', so to speak.

-- 
========================================================================
I'm not irresponsible--I'm out of control
http://www.unixgeek.com/cgi-bin/motd.pl - PGP email preferred