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

Close contracts if there are no suitable options to roll to #439

Closed
brndnmtthws opened this issue May 31, 2024 · 3 comments · Fixed by #442
Closed

Close contracts if there are no suitable options to roll to #439

brndnmtthws opened this issue May 31, 2024 · 3 comments · Fixed by #442
Labels
enhancement New feature or request

Comments

@brndnmtthws
Copy link
Owner

brndnmtthws commented May 31, 2024

If you don't like this behaviour, the alternative would be to avoid rolling puts. You can adjust the settings to close the positions when you hit some P&L, and the cycle will continue by writing new puts next time around.

That would be nice if this would work sequentally.

Short explanation what is in my mind:
Selling Puts, Underlying increases, rolling will not find a suitable contract (e.g. too low premium) then check if Pnl to close position is reached, and possibly close position. Does that makes sense to you?

Second option would be to reduce the options. The rolling process looks to me to always roll the same amount. But when 3 options now exceed the weight, we could reduce to 2 options.

Btw is there anywhere some room to chat about this stuff? Discord? The Element channel does not seem to work?

Originally posted by @robby28-11 in #347 (comment)

@brndnmtthws brndnmtthws added the enhancement New feature or request label May 31, 2024
@brndnmtthws brndnmtthws changed the title If you don't like this behaviour, the alternative would be to avoid rolling puts. You can adjust the settings to close the positions when you hit some P&L, and the cycle will continue by writing new puts next time around. Close contracts if there are no suitable options to roll to May 31, 2024
@robby28-11
Copy link

Was just thinking about that function. I think it would be helpfull to have it configurable for each ticket. Something like „roll“, „close“, „roll_or_close“. This way it would also be easy to end the wheel for a ticker and having the mentioned enhancement or the current behavior.

@brndnmtthws
Copy link
Owner Author

I like that suggestion, but it's a bit tricky to change while maintaining backward compatibility. I could require people migrate their config, but that will probably annoy some.

For now, I'll probably just add a boolean option to close if it can't roll.

@robby28-11
Copy link

You could define „roll“ as fallback if it is not defined in the ticker, this way it would work as before without the need to change the config.

But just adding the option in general is also a nice first step 👍

brndnmtthws added a commit that referenced this issue Jun 4, 2024
If we try to roll a position and can't find a suitable contract to roll
to, allow the option of closing the position out instead.

This can be configured by setting `roll_when.close_if_unable_to_roll =
true`, or per-symbol with `symbols.<symbol>.close_if_unable_to_roll =
true`. Disabled by default.

This closes #439.
brndnmtthws added a commit that referenced this issue Jun 4, 2024
If we try to roll a position and can't find a suitable contract to roll
to, allow the option of closing the position out instead.

This can be configured by setting `roll_when.close_if_unable_to_roll =
true`, or per-symbol with `symbols.<symbol>.close_if_unable_to_roll =
true`. Disabled by default.

This closes #439.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants