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

[amibroker] Comsec Profile



PureBytes Links

Trading Reference Links

Hi

I am trying to backtest some ideas I have for FOREX trading.

I have two questions, but first som basic info about my system.

The concept is that I risk 10% with a S/L of 2*ATR in 1h chart. My
trailing S/L is slow, so the system lets me add in new positions if
some conditions are meet (e.g. new top after the latest buy signal).
This has as an effect that I would like to make Amibroker buy more
then once before I sell. I can hold a position in ~ 8-16 weeks (a 
function of a slow SAR). 

Now to my questions;
1// How do I do in Amibroker so I can buy on all raw signals
(unfiltered), and later on sell all open positions when I get a sell
signal?

For example
Pos 1, buy at 1.2 and let the profit run.
Pos 2, buy at 1.3, but where stopped out at 1.25 due to ApplyStop
Pos 3, buy at 1.5 and let the profit run
Sell pos 1 & 3 (the remaining open pos) at 1.8 due to a sell signal.

2// I wold like to have a 10% risk of my total capital at every buy 
signal. When I try to make the positionsize depend on my risk 
Amibroker always takes my INITIAL Equity and calculate the risk. 

My formula for sizing looks like;
  TrailStopAmount = 2* ATR(14); 
  Risk = 0.1*Equity(0,-2);
  PositionSize = (Risk/TrailStopAmount)/100;
  

Thanks / Tobias



Send BUG REPORTS to bugs@xxxxxxxxxxxxx
Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
-----------------------------------------
Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx 
(Web page: http://groups.yahoo.com/group/amiquote/messages/)
--------------------------------------------
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/