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

Support for multiple OCO stop limit and stop market orders? #3

Open
kpapad904 opened this issue Nov 30, 2022 · 3 comments
Open

Support for multiple OCO stop limit and stop market orders? #3

kpapad904 opened this issue Nov 30, 2022 · 3 comments

Comments

@kpapad904
Copy link

Hello and thank you very much for creating icli, I've just come across it and both its current functionality as well as the TODO roadmap look incredible!

I have a question: Could icli be used to manage / automate a multi-leg options strategy that includes multiple OCO stop orders, such as the 0-DTE SPX Breakeven Iron Condor ?

More info here:
https://www.sandvand.net/2022/08/21/learnings-from-0dte-breakeven-iron-condor/
https://www.sandvand.net/2022/01/02/0dte-breakeven-iron-condor/

@mattsta
Copy link
Owner

mattsta commented Dec 3, 2022

That's a good question!

Short answer: partially yes, but it's not done yet, but it will probably get added eventually? It would be another nice tool to add for an "automatic profit accumulation" option.

Longer answer:

I do have an unreleased IC command automation where you give it a symbol name, percent width from current price to start the wings, the point width of the wings, and the spend amount; then it places the 4-leg order based on the current ATM price and each leg quantity based on the amount of spend/margin needed for the width (also adjusted for the credits received).

But, I never got around to testing the command extensively on live trades before my toy account blew up again. Maybe next year when I can jump above PDT again.

As for stops and OCO or OTOCO orders, icli is currently fairly weak in those areas when it comes to posting broker-side complex orders.

I had mostly ignored the interface for creating stops (or OCO et al) due to focusing on active algo day trading automation where we create client side live price trackers then immediately place orders to enter/exit based on various signal/trigger/crossover scenarios (so basically we are managing our own stops external to the broker/exchange then placing a live exit order when prices move against our positions too much). Theoretically it's better to use a live pricing model instead of static entry / exit numbers due to the adversarial interactions of stop loss level hunts paired against cutting winners too early when they are still working in our favor (sometimes a more useful exit for profit taking can be "trailing stop limit if touched" orders, but those are also tricky to get right across different instrument classes).

@kpapad904
Copy link
Author

Hi Matt, I'll be looking forward to new features!

Regarding the PDT restriction, I'm not affected (EU resident) but I've seen many who were affected moving to Options on Futures (e.g. ES, MES, ZB, ZN and sometimes commodities like metals, agricultural etc), typically with defined risk strategies like ICs.

I could point you to a couple of strategies which have been mentioned favorably by folks at Reddit, and which would not require constant monitoring during market hours (like many 0-DTE SPX strategies do ...)

@kpapad904
Copy link
Author

Hi again Matt,

Quick comment to let you know about the 0-DTE SPX MEIC (Multiple Entries Iron Condor) strategy, which has been quite popular recently among the members of the "Tastytrade Options" Facebook group https://www.facebook.com/groups/1930565613719977/

There is also a video presentation by Tammy Chambless:
https://www.youtube.com/watch?v=cOoOaKvHRqk

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