I am new to Quantopian, this is my first published backtest, any type of criticism is welcome.
I am new to Quantopian, this is my first published backtest, any type of criticism is welcome.
Be cautious of your leverage (ie your borrowing). I typically always record the leverage and make sure (at least in initial testing) that it never goes above one. You should always be able to adjust it later for higher returns if desired. Add a line like this in a scheduled function
record(leverage=context.account.leverage)
Attached is your algo with this added. Note your leverage varies from 1.6 to over 7. Not really viable in live trading. The Q contest requires a max leverage of 3.