Drag Entries and Exits onto the Model surface. Each Entry should have at least one Exit under it. The Exit type (Sell, Cover) should match the Entry type (Buy, Sell)
You can drag one or more Conditions onto the Entries and Exits to define the Model's trading logic. If a Condition uses an indicator, you can choose any technical indicator, or a price component like open, high, low, close or volume.
You can drag a Qualifier onto a Condition to impose different behavior on it, such as enforcing that it occurs a certain number of days in a row.
I liked the smooth look of 32's equity curve, rather nice for a simple mean reversion model. But I wanted it to perform a little better, so I tweaked three things. First, in Settings I changed the Max Open Positions to 0 instead of 10. For unknown reasons, this lets the model properly hold up to 10 positions :-) which helps a lot here. Second, I wanted to add another Condition block to the Buy, such that the stock had to be on a good upswing overall. I used 1-month momentum ROC(20) > 1.5% for this. But this also cuts down on the number of trades available more than I'd like. So third, I went to the Qualifier for N Times in N Bars and loosened it up a little, to 12 bars instead of 8 bars in the original.
What did I get? Overall CAGR is up, in line with SPY now. Exposure is only slightly higher (still under 50%). Sharpe ratio has improved a bit to up around 1.0, and MDD is about the same (a little less than SPY). Nice!
But... hmmm, did I overfit this simple strategy? Well, I did play around with some of those params, and tried and rejected some things (like the 10 month momentum should also be positive), so technically, maybe I did. So what happens when we extend the timescale to the full 20 year backtest? Definitely a degraded performance relative to the original. Model 32 shines from 1999-2009 compared to this overfit misfit. You can run the numbers yourself if you want to see just how humbling this simple exercise was for me. At least it beats SPY. But that's about all you can say for it.
You will need to Sign In in order to save your Models.
When saving a Model, provide a short and descriptive name that summarizes its spirit.
Also, provide a brief description that explains the logic of your Model, and any other interesting background material you'd like to include.
When you're ready, please Publish your Model so other members of the Quantacula community can review and learn from it.
Remember, in the free membership, you can save only 3 non-published Models. Publish a Model to open up one of your free Model slots. Premium members can save an unlimited number of private Models.
The settings here control what data is used when you backtest your Model, as well as the position sizing. Settings information is saved when you save your Model.
|Maximum Drawdown %|
|Maximum Drawdown Date|
|Interest and Commission||Model||Benchmark|
|Cash Interest Earned|
|Margin Interest Paid|
|Number of Positions|
|Number of NSF Positions (not taken)|
|Average Profit %|
|Average Hold Time (Bars)|
|Number of Winners|
|Winners Avg Profit|
|Winners Avg Profit %|
|Winners Avg Hold Time (Bars)|
|Number of Losers|
|Losers Avg Loss|
|Losers Avg Loss %|
|Losers Avg Hold Time (Bars)|
|Position||Symbol||Quantity||Entry Date||Entry Price||Last Price||Profit||Profit %|
|Position||Symbol||Quantity||Entry Date||Entry Price||Exit Date||Exit Price||Profit||Profit %|