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

[amibroker] Re: SAR Help



PureBytes Links

Trading Reference Links

Ooops I pressed the Send button befor I was done. So here is the algo again:
 
Buy = Condition1;
BuyPrice = X;
Sar = X-Y;
Sell = Cross(Sar, C);
 
While(Long AND Sell Not Triggered)
{
        Calculate New Sar using Sar formula;
        Plot(Sar);
}
 
I just want the SAR to eb plotted for the duration I am long in the trade. I am not sure
how to implement the while loop as given in the algo above. Please help.
 
Thanks
Pankaj
On 1/1/06, Pankaj Chawla <pankaj013@xxxxxxxxx> wrote:
Hi
 
I need help with some piece of code. I want to use SAR as a trailing SL for my long only
system. The SAR should start from the buy day and move on till Sell happens with SAR
crossover. The existing SAR function doesnt allow plotting it from the buy Day.
 
Here is my algo:
 
Buy = Condition1;
 
if (Buy)
      InitialSar = Some value below Bur Price;
else
 



Please note that this group is for discussion between users only.

To get support from AmiBroker please send an e-mail directly to
SUPPORT {at} amibroker.com

For other support material please check also:
http://www.amibroker.com/support.html





SPONSORED LINKS
Investment management software Real estate investment software Investment property software
Software support Real estate investment analysis software Investment software


YAHOO! GROUPS LINKS