PureBytes Links
Trading Reference Links
|
Hi Everyone,
I'm a total newb to AmiBroker and I'm trying to test an idea I have for a fairly simple trend following system.
I'm having problems programing my exit/stop system.
Here's the concept in a nutshell:
- Part #1 - Maximum Loss Protection : Initial stop is a fixed dollar
amount based on volatility - for some reason even this part isn't
giving me the results I expect, in backtests I'm getting stopped out
on way smaller moves than I want.
StopAmount = 2.0 * ATR( 20 );
ApplyStop( 0, 2, StopAmount, 1 );
- Part #2 - Lock in Profits : If my target of say 15% profit is
reached, then I want to switch to a trailing 1% stop.
- Part #3 - Timed Exit : Since this is a trend following system, if
my target or stop are not reached in "x" number of days (say 15 as a
starting point) then sell at the close of the 15th day.
Thanks for any help or if you could just point me in the direction of
similar code for the logic I'm trying to implement, I'd really
appreciate it.
Jon
------------------------------------
**** 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/
|