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

[amibroker] Profit Target OR Sell at Close



PureBytes Links

Trading Reference Links

Hi,

Really simple question guys lol.

I've designed a gap fading system that works reasonably well.
The entry is just very simple (one condition only to buy opening gap downs) and I enter at the open and exit at the close.

I've found that by examining the MFE on my losing trades, most of them were in profit (some significantly) during the trade but then got sold off during the rest of the day and ultimately was closed at a loss.

So Im thinking that with some sort of profit target, maybe 0.5-1%, the results would be enhanced nicely.

So my initial exit code was just.

Sell = C;
SellPrice = C;

And now I've changed it to;

Sell = 0;
ApplyStop(1,3,1,1,0);

But this produces trades that are held for ages, so can somebody please help me specify to exit as soon as the Profit target is reached OR exit at the close, whichever comes first. Some sort of If ot IIF function maybe?

Thanks.

Nizar.



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

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