You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I think it makes sense to include the stop loss in this equation while keeping that same risk level because you only stand to lose the difference between the buy price and the stop-loss.
So if you buy 40 shares at $100 a piece, that's 2% of your respectable $200k portfolio. However, if your stop-loss is $95, you only stand to lose $5 on each share, or $200 total - which would be .001 of your portfolio. I assume that's how risk is calculated here.
When calculating the number of shares to buy, I think the formula you use should be
instead of
Momentum-Trading-Example/algo.py
Lines 253 to 255 in be43528
I think that the number of shares you buy should be independent of the difference between the current stock price and your stop loss.
For example:
The above order would make up 2% of your portfolio, higher than the 0.1% of your portfolio that you said you would allocate to any one position
The text was updated successfully, but these errors were encountered: