The main changes made were coming up with market switching in response to different market environments as loosely suggested by multiple sources. I also implemented but commented out some very poorly designed trend trading and hedging attempts. (although I do hedge position sizes slightly based on how many of my stocks are currently doing bad)
Some things to work on are definitely the entry of the system, when it predicts market turns will occur, position-sizing, and rebalancing. However, it meets my needs (namely choosing stocks during different market conditions) since I plan to combine it with some discretionary trading. The point of the current general calculations of turns is to get it right over 50% of the time and within a couple of weeks, to emulate the correct market conditions. I plan to eventually add some of the other ideas I have on how markets work into it, but I suspect they won’t add much to returns. Another alternative is raising stop losses whenever the market drops 10% or more. I think if I adjust the factors ratios, I can deliver significant outperformance, but this is a venture for later. This is far from an optimal method, as I'll soon post a notebook of one that outperforms significantly; it merely reflects how I think I would realistically trade.
@Vladimir
a) In real life, you can take much higher than 4x leverage if you're on a personal account without nominally taking on higher risk via options.
b) TVIX no longer trades so I believe I switched it to UVXY (can't really remember), but it's more of a way to hedge against downturns. In real life, I would likely buy SPY Puts or something of that ilk
c) Slippage is currently of no concern to mean since I'm not a millionaire and have a small personal account. Plus I plan to time entries in a discretionary manner (which has arguable effectiveness)