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

[amibroker] Barsince for last buy arrow



PureBytes Links

Trading Reference Links


I'm having trouble keeping the value of  bars since of the last green
arrow occured. When I use the code below it gives me the barsince,     
but will start to recount when CCI(9) becomes a buy again. Is there a
way to find the barsince of the Green Arrow?

I'm trying to sell at certain times in the future and do not want to
use the  N-Bar stop in the Back Tester.

Buy =  CCI(9) > 0;

paidt = BarsSince( Buy == 1 );

printf("barssince = %g\n", BarsSince( Buy1 == 1 ));

Sell = paidt > 14;

Buy  = ExRem(Buy,Sell);
Sell = ExRem(Sell,Buy);

Thanks

Marty






------------------------ Yahoo! Groups Sponsor --------------------~--> 
What would our lives be like without music, dance, and theater?
Donate or volunteer in the arts today at Network for Good!
http://us.click.yahoo.com/Tcy2bD/SOnJAA/cosFAA/GHeqlB/TM
--------------------------------------------------------------------~-> 

Check AmiBroker web page at:
http://www.amibroker.com/

Check group FAQ at: http://groups.yahoo.com/group/amibroker/files/groupfaq.html 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/amibroker/

<*> To unsubscribe from this group, send an email to:
    amibroker-unsubscribe@xxxxxxxxxxxxxxx

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/