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

[amibroker] Same Bar Long and short signal backtest question



PureBytes Links

Trading Reference Links

Since my first post (See below) I began to wonder if triggering both a long and short trade in the backtester or through an exploration on the same bar is possibe.  If the answer is yes can someone please explain how to do it?  

Thanks in advance,

Spike




I am trying to back test a day trading system using end of day data. The system can produce a long and short position on the same day. All positions are closed at a profit target or on the close. The majority of the time the (98%) the system only produces 1 trade, either long or short. However, on the days when the system triggers both long and short trades the back test result is only capturing the long trade. I have also coded the system as an exploration and the exploration will only capture the long position.

Under the settings I have selected reverse entry forces exit and allow same bar exit. I know there is a way to for AB to pick up both signals but I am stumped?

The system has the following rules:

X is less than Y
Buy Entry level & Short target = x
Sell Short Level & Buy target = y

Long entry 1 Go long when open is less than or equal to x
Long entry 2 Go long when open is greater than or equal to y AND low less than
or equal to x

Short entry 1 Go short when open is greater than or equal to y
Short entry 2 Go Short when open is less than or equal to x AND high is greater
than or equal to y

Long exit = if high is >= Y or MKT on close

Short exit = if low is <= x or MKT on close


Any suggestions on how to get the back test and the exploration working is appreciated.

Thanks in advance,
Spike




------------------------------------

**** IMPORTANT PLEASE READ ****
This group is for the discussion between users only.
This is *NOT* technical support channel.

TO GET TECHNICAL SUPPORT send an e-mail directly to 
SUPPORT {at} amibroker.com

TO SUBMIT SUGGESTIONS please use FEEDBACK CENTER at
http://www.amibroker.com/feedback/
(submissions sent via other channels won't be considered)

For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
http://www.amibroker.com/devlog/

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:
    amibroker-digest@xxxxxxxxxxxxxxx 
    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/