Buy and Hold Strategy using 100% Equity doesn't take trades
Author: Panache
Creation Date: 3/9/2013 9:13 AM
profile picture

Panache

#1
I created a very simple strategy to generate performance data by period of a buy and hold strategy on SPY (as a basis to compare my other strategies).

CODE:
Please log in to see this code.


I'm using the following settings:
Scale: Daily
Data Range: 1/1/2006 to 12/31/2012
Starting Capital: 1,000,000
Position Size: 100% of equity

Under Preferences, neither Slippage nor Round Lots is activated.

As expected, the Performance for All Trades is exactly the same as Buy & Hold, as long as the Date Range begins on 1/1/2007 or later.

When I use 1/1/2006, 1/1/2005, 1/1/2004 or 1/1/2002 as the beginning of the Date Range, I get no trades (and therefore no performance information under All Trades), although it does still show performance for Buy & Hold. If I reduce the Position Size to 99% of equity, the Strategy performs as expected (although there is obviously a difference between the performance data for All Trades and Buy & Hold).

However, if I use 1/1/2003, 1/1/2001 or 1/1/2000 as the beginning date (with 100% of equity), the Strategy performs as expected.

If I change BuyAtMarket to BuyAtClose, using 1/1/2003 and 1/1/2001 as the beginning date, it doesn't generate any trades.

I'm assuming the problem is that somewhere in the program, it is rounding the number of shares up causing my strategy to attempt to buy more than 100% of equity.

Is there anything I can do to fix the problem?
profile picture

Eugene

#2
Check out "100% of Equity Sizing" in the Wealth-Lab User Guide. This introduces an important concept and also explains why you may get skipped trades on particular dates using 100% equity.

The Position Options PosSizer's "Skipped trade solution" option can help with that by adjusting the basis price.
This website uses cookies to improve your experience. We'll assume you're ok with that, but you can opt-out if you wish (Read more).