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

[amibroker] Re: Trade stop after GapUp or GapDown



PureBytes Links

Trading Reference Links

Hmm, maybe I am doing something wrong. I will give a part of the 
code. Should have provided that earlier...


BTStartTime1 = ParamTime("Backtesting SOD","09:00:01");
BTEndTime1 = ParamTime("Backtesting EOD","17:20:00");
EOD = TimeNum() >= BTEndTime1;
SOD = TimeNum() >= BTStartTime1;
SOD = SOD != Ref(SOD,-1);
EOD = EOD != Ref(EOD,-1);
InSession = Flip( SOD, EOD);

//then comes my system//

EnableSessionTiming = ParamToggle("Enable Session Timing","NO|YES",1);
if( EnableSessionTiming )

Buy   = 

Sum(buysig,pds21) > Sum(Sellsig,pds21) AND InSession AND NOT EOD AND 
NOT GapUp() OR GapDown(); 


I hope this makes it something clearer....

The code for the startsession was posted here on the forum before, I 
borrowed it :-)

Greets Ronald 




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 NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
http://www.amibroker.com/devlog/

For other support material please check also:
http://www.amibroker.com/support.html
 
Yahoo! Groups Links

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

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/amibroker/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:amibroker-digest@xxxxxxxxxxxxxxx 
    mailto:amibroker-fullfeatured@xxxxxxxxxxxxxxx

<*> 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/