Hi everyone,
I’m trying to adjust my strategy so that it trades a percentage of my account equity instead of using a fixed number of contracts.
Ideally, I’d like the strategy to automatically calculate position size based on my current equity — for example, allocate 2% of the account equity per trade. That way, the position size scales up as the account grows, and decreases after losses.
Has anyone implemented this before in ProBuilder code?
I’d really appreciate an example or some guidance on how to calculate and set the position size dynamically.
Thanks a lot in advance!
/Osca