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

[amibroker] Re: Managing drawdowns (was % channels)



PureBytes Links

Trading Reference Links

hi Pal,

myself I do not use fractions of my account for trading as the Kelly 
formula suggests. This is only usefull imo for the gambling example I 
gave. Still, I use the concept of the Kelly formula to treat my 
trades as if I was making a bet. I define the profit % for a winner 
and the loss % for a looser since you can take a profit e.g. at 1% 
and a loss at 10%. If I know these I can calculate how successful the 
system needs to be in order to be profitable.

E.g. for a system where you take a profit at 2% and a loss at 10% you 
need at least 85% of the trades to be winners for the system to be 
profitable and then the profit is only marginable (about 11% profit 
after 100 trades). Taking a profit at 1% and a loss at 20% leaves you 
with a system that needs a chance of success greater than 96% ..... 
this looks rediculous but when choosing entry points carefully 
chances your trades will make a 1% profit can be pretty good.

This is the approach I try to follow.

No, I have no experience yet with the money management formulas in 
AB. At the moment I am playing with the portfoliotrader.

regards, Ed


--- In amibroker@xxxxxxxxxxxxxxx, "palsanand" <palsanand@xxxx> wrote:
> Thanks Ed.  I have modified my available_equity = 0.5 * 
Usable_Margin 
> equation which previously used 0.42 as the coefficient.  I then 
> divide the available_equity equally among the positions I intedn to 
> trade (diversification).  This way I can enter at MOO (previous 
days 
> close price) and double up at High of Day/Low Day as predicted by 
the 
> AFL pivot points code, with the assumption (hope) that MOO is the 
> best price to enter and that predicted High/Low of Day may never be 
> touched.  This method may approximate the kelly formula method of 
> using 0.25 as the optimal fraction of the available_equity.
> 
> Also, I came across some interesting code which might be of use:
> 
> $max_risk_per_trade = .025; #never lose more than 2.5% per trade 
> $risk_in_trade = $entry_price - $sell_stop; #percent decline to hit 
> stop 
> $coeff = $max_risk_per_trade / $risk_in_trade; 
> $shares_to_buy = ($coeff * $equity) / $entry_price; 
> 
> There are also a lot of money_management formulas built-in into AFL 
> in AB.  I don't know how exactly to include these formulas with my 
> available_equity formula to further enhance money_management.  Any 
> thoughts?
> 
> rgds, Pal
> 
> 
> --- In amibroker@xxxxxxxxxxxxxxx, "ed2000nl" <pablito@xxxx> wrote:
> > money management is an interesting topic. Is anyone 
using "Optimal 
> f" 
> > or other ideas by Ralph Vince? It doesn't make too much sense to 
me 
> > that once you have a winning system one needs to calculate the 
> > optimal fraction for each wager so I never looked at it in detail.
> > 
> > Interesting though is the example of the Kelly method. The 
problem 
> > is: what fraction of your account should you use for each bet / 
> wager 
> > to maximize your profits as fast as possible when the chance to 
win 
> > is 50%. Further constraints: a winning trade gives you a 200% 
> return 
> > and a losing trade gives a 100% loss. The answer is: 0.25 (this 
you 
> > can calculate using the Kelly formula but it is easy to simulate 
> the 
> > situation with a little program).
> > 
> > Then I had the idea to treat my trades as "discrete" bets / 
wagers 
> in 
> > order to find an optimal fraction of the account or just to find 
> out 
> > if a system could be profitable. I had the idea to use 1/100 of 
my 
> > account for each bet and take a profit quickly at 2% and use a 
> > stoploss of 100%. In situations like this your system needs to be 
> > pretty good. But the higher your stoploss the greater the chances 
> are 
> > that one day it will make a profit. And choosing the entry point 
> > carefully, chances are pretty good you will be able to sell it 
with 
> a 
> > 2% profit.
> > 
> > I like the idea of exposing just a small amount of the account to 
a 
> > single trade and also to take a profit quickly.
> > 
> > I must say I didn't finish working on these ideas yet in 
detail.... 
> > since I am in the process of switching to Amibroker. But I would 
> like 
> > to read about other ideas about "money management"
> > 
> > rgds, Ed
> > 
> > 
> > 
> > 
> > --- In amibroker@xxxxxxxxxxxxxxx, "Howard Bandy" 
<howardbandy@xxxx> 
> > wrote:
> > > Hi Guys -
> > > 
> > >  
> > > 
> > > Remember that there is a limit to the amount of doubling up 
that 
> > can be done
> > > when using Martingale money management.  One of the reasons 
> casinos 
> > say $5
> > > minimum $500 maximum is so that Martingales hit the $500 limit 
> and 
> > cannot
> > > recover the original $5 bet.  Our own limits are our trading 
> > accounts.  Do
> > > the arithmetic and see how many consecutive losses it takes to 
> hit 
> > you own
> > > person limit.  Then look at the summary of your trading system 
> and 
> > compute
> > > the probability that you will have that many consecutive losses.
> > > 
> > >  
> > > 
> > > Another reason to be wary of Martingale systems is that they 
> > require ever
> > > larger bets as successive losing trades occur.  One of the 
> methods 
> > many of
> > > us use to determine whether a trading system is broken is by 
> > looking at the
> > > sequence of trades and / or the equity curve.  We Decrease 
trade 
> > size or
> > > stop using a system when it is taking serious losses.  
Martingale 
> > systems
> > > require Increasing the size of the bet / trade when losing.
> > > 
> > >  
> > > 
> > > Howard
> > > 
> > >  
> > > 
> > > -----Original Message-----
> > > From: palsanand [mailto:palsanand@x...] 
> > > Sent: Tuesday, October 28, 2003 9:23 PM
> > > To: amibroker@xxxxxxxxxxxxxxx
> > > Subject: [amibroker] Re: Managing drawdowns (was % channels)
> > > 
> > >  
> > > 
> > > Dave,
> > > 
> > > There is a good link I came across:
> > > 
> > > http://www.arbtrading.com/moneymanagement.htm
> > > 
> > > I like the Anti-Martingale and Martingale (doubling up) systems 
> to 
> > > manage drawdowns.  I would use a combination of these systems, 
so 
> > > that when I'm losing money I would use Martingale system and 
when 
> > I'm 
> > > finally making money with the final position, I would be 
> > > automatically switched over to Anti-Martingale system, but may 
> most 
> > > likely exit losing positions at break-even price.  I would 
double 
> > up 
> > > only when I get stronger signals verfied by OB/OS conditions in 
> the 
> > > subsequent session, so that my system of using 3BSMA for the 
next 
> > > session is temporarily suspended.  It does take usually about 3 
> > days 
> > > for a trend-change to fully develop.  I would not double up 
> beyond 
> > 3 
> > > consecutive days, because if you are wrong 4 times in a row, 
most 
> > > likely the market is starting a new trend in the opposite 
> direction 
> > > and will go against you and so better to exit.  I have done 
this 
> > many 
> > > times, as I find it impossible to optimize my entry points.  
But 
> > the 
> > > safest course is to wait for the actual Trend-change signal 
> > verified 
> > > by OB/OS conditions, then you may never have to double up but 
you 
> > may 
> > > miss some signals.  This may sound crazy for some but it does 
> seem 
> > to 
> > > work for me especially with the AFL pivot points to predict the 
> > Next 
> > > bar approximate High/Low of Day and appropriate position sizing.
> > > 
> > > Regarding whether your system has stopped working or not, it is 
> > hard 
> > > to say.  I would try to improve the system performance using a 
> > system 
> > > of filters, stops and walkforward testing.  Easier said than 
> done...
> > > 
> > > Regards,
> > > 
> > > Pal
> > > 
> > > 
> > > --- In amibroker@xxxxxxxxxxxxxxx, "Dave Merrill" 
<dmerrill@xxxx> 
> > > wrote:
> > > > I've been wondering, could I trade a system with 50% average 
> gain 
> > > per year
> > > > since '95, and max system drawdown of 40-50%. even if I've 
seen 
> > > that in
> > > > backtests beforehand, could I really look at that kind of 
drop 
> in 
> > > my account
> > > > and still believe I was doing the right thing? or would I 
think 
> > > it'd finally
> > > > just stopped working? and if I am able to ignore that much 
> > > drawdown, how
> > > > would I know if it really *had* stopped working?
> > > > 
> > > > by the half-the-gain-twice-the-drawdown tolerability rule, 
this 
> > is a
> > > > non-starter.
> > > > 
> > > > dave
> > > >   Defense ... Yep or as I've said it's not what you make, 
it's 
> > what 
> > > you
> > > >   keep.  DD's are killers from lots of aspects not just in 
> terms 
> > of
> > > >   what they do to your account balance but also what they do 
to 
> > ones
> > > >   ability psycologically to trade and stay with systems that 
do 
> > > work.
> > > 
> > > 
> > > 
> > > 
> > > 
> > > 
> > > Yahoo! Groups Sponsor
> > > 
> > > 
> > > 
> > > ADVERTISEMENT
> > >  
> > > 
> > 
> 
<http://rd.yahoo.com/M=244522.3707890.4968055.1261774/D=egroupweb/S=17
> > 056321
> > > 
> > 
> 
98:HM/A=1595055/R=0/SIG=124j83ehr/*http:/ashnin.com/clk/muryutaitakena
> > ttogyo
> > > ?YH=3707890&yhad=1595055> Click Here!
> > > 
> > > 
> > >  
> > > <http://us.adserver.yahoo.com/l?
> > M=244522.3707890.4968055.1261774/D=egroupmai
> > > l/S=:HM/A=1595055/rand=818896749> 
> > > 
> > > 
> > > Send BUG REPORTS to bugs@xxxx
> > > Send SUGGESTIONS to suggest@xxxx
> > > -----------------------------------------
> > > 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 
> > > 
> > > Your use of Yahoo! Groups is subject to the Yahoo!
> > > <http://docs.yahoo.com/info/terms/>  Terms of Service.


------------------------ Yahoo! Groups Sponsor ---------------------~-->
Buy Ink Cartridges or Refill Kits for your HP, Epson, Canon or Lexmark
Printer at MyInks.com. Free s/h on orders $50 or more to the US & Canada.
http://www.c1tracking.com/l.asp?cid=5511
http://us.click.yahoo.com/mOAaAA/3exGAA/qnsNAA/GHeqlB/TM
---------------------------------------------------------------------~->

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 

Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/