Wednesday, October 30, 2019

First trade of the Samvat

1
After spending over 30 hours backtesting over the Deepavali weekend, I am trying out a momentum based trading system.

During the past 19 months, I have restricted myself to mechanically trading variations of the range breakout system. The results have been good but with big hiccups. The breakout based system works extremely well for many consecutive months, and then suddenly goes into extended drawdowns. I had superb profits from April 2018 to July 2018, followed by a nerve wracking drawdown from September to November 2018, then serious profits from December 2018 to mid-June 2019, and now an extended drawdown from mid-June onwards.

On analysis, I have found that I have been in loss (just below breakeven) in long trades, and short trades have been very profitable. Part of the reason for this is that I missed out on a few great long trades (luck?). I have known this fact for sometime now, but I continue to take long trades - I have some sort of cognitive bias towards symmetry of breakout trades. Also, out-of-sample backtest of previous years do not show a significant advantage for short trades - in many years, longs are significantly more profitable than shorts.

I am trying this new momentum based system to hopefully increase my win rates and reduce the extended drawdown periods. Yesterday, I traded YESBANK, while also watching TATAMOTORS, INFY and SBIN. The entries for this system are mechanical, but for now, until I get used to this system, I have left a minor scope for discretion in scrip selection and stop trailing.


First trade of the Samvat
First trade of the Samvat



Read Full Post »

Saturday, July 20, 2019

Backtesting Money Management

0
This is a backtest of the data available in my trading ledger. The focus is solely on improving the Money Management, and the trades and Trading Plan are ignored in this analysis.

The period covers all my trades in the current financial year so far - April 01, 2019 to July 19. 2019. Except for 4 or 5 days, I have traded on all the trading days this year.

Current Money Management:

  • This year, additional margin requirements have been imposed by the exchange on which I trade - NSE. These margin restrictions do not allow me to bet the Kelly Optimal Position Size even if I want to. Also, I have recently become aware of the benefits Fractional Kelly in reducing Volatility Drag. So, betting a fraction of the Optimal Position Size is what I do.
  • Whenever I end a day in profit, I usually transfer out a part of the profits to my bank (I call it Dividend 😀). Whenever I end a day in a loss, I usually transfer in some money from my bank into my trading account (I call it Dividend Reinvestment 😀). So, whatever I am doing is slightly different from classic Kelly Money Management.

Backtesting the Money Management:

I tested the data in my trading ledger by varying the fraction of my daily profit that I transferred out to the bank account, and the fraction of my daily loss that I compensated for by transferring money in from my bank account to my trading account.

Here are the results of the backtest (all amounts in Indian Rupees):

Profit and Net Dividend vs. Transfer In/Transfer Out combinations
Profit and Net Dividend vs. Transfer In/Transfer Out combinations


The first table shows the Profit that could have been achieved for different fractions of P&L transferred in/out. The second table shows the Net Dividend (Transferred Out - Transferred In) for different fractions of P&L transferred in/out.

I have blanked out all combinations of Transfer In/Transfer Out that would have resulted in:
- A final Trading Account Balance lower that my initial Trading Account Balance, and/or
- A negative Net Dividend on any day of the backtest.

The lower left portions of the tables are empty because those combinations result in negative Net Dividends. The upper right portions of the tables are empty because those combinations result in lower final Trading Account Balances.

I have also highlighted (in yellow) the 5 best results for Profit and Net Dividend. These values are somewhat higher than the actual results that I achieved. I am neither a mathematician nor a statistician, and haven't analyzed this further... but one thought that occurs is whether this Transfer In/Transfer Out method can improve the performance of Fractional Position Sizing based Money Management.

I am not aware if there has been any study on this type of Money Management... and to that extent this is my original research. You bet I'll analyze this further. Right now, these are just observation from a backtest result and there are no definite conclusions that I can present.


Read Full Post »