Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Scaled Position #749

Open
tama853 opened this issue Sep 29, 2024 · 2 comments
Open

Scaled Position #749

tama853 opened this issue Sep 29, 2024 · 2 comments

Comments

@tama853
Copy link

tama853 commented Sep 29, 2024

Hello, I really enjoy vectorbt, but I am not finding the correct info on what I am looking for. Here is a quick example:
I am wanting the position to scale up 10% for each buy signal for the first 2 indexes, then sell all of it on the first close signal. Is this possible with "percent" sizing? I am only ever showing the first trade happens and the additional scaling never occurs.

image

@polakowo
Copy link
Owner

Use accumulate='addonly'

@tama853
Copy link
Author

tama853 commented Oct 12, 2024

Thank you so much! And for this option, does it matter if I track the size so it closes it all, or it will always close the entire position?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants