Lean
Lean copied to clipboard
Enable Greeks and Implied Vol. from Options History Request
Expected Behavior
Enable accessing Greeks and Implied Volatility in a historical data request for options data. This is a handy feature and will help with calculation of things such as IV Rank without needing to implement custom functions using Rolling Windows.
Checklist
- [x] I have completely filled out this template
- [x] I have confirmed that this issue exists on the current
master
branch - [x] I have confirmed that this is not a duplicate issue by searching issues
- [x] I have provided detailed steps to reproduce the issue
Would love to see this feature!
I'll second that. It would answer my question.
Is there a way to contribute to this? If we fork LEAN and implement in Python will that be sufficient?
Any update on this?
I was looking into this a bit. Looks like Resesarch OptionHistory.cs has slice referenced as a private variable; curious if it was public would it be able to be used for OptionPriceModel Evaluate.
https://github.com/QuantConnect/Lean/blob/43e9cad2d6407d4d2d3c1a5fb9788e44a97a8a7d/Research/OptionHistory.cs#L29
https://github.com/QuantConnect/Lean/blob/43e9cad2d6407d4d2d3c1a5fb9788e44a97a8a7d/Common/Securities/Option/IOptionPriceModel.cs#L35
That's as far as I have gotten.
I have talked to others that are using Backtesting Options IDE to gather pricing data; saving it to ObjectStore and then referencing it from Research notebook to get around the fact that Option Pricing object model is not available from Research. Seems to be a descrepency between the Options object model being worked from backtest versus research.
Let me know if anyone makes any more progress. Thanks!
This is very promising. Thank for sharing this.
Is this resolved? How to use it?
Is there an update on this?
Hi all, no update yet sorry. We're currently working on daily options and then will explore this again on a much smaller dataset which should make it an easier issue to start working on and to verify against third-party greek sources which are all generally daily.
We appreciate it's an important feature to make options easier and should start work on it this year. The best way to support us is volunteering time in our slack/discord/community or sponsoring LEAN.
Been around 11 months, has there been any progress made with this?
IV and IVR basically indicate if a contract is cheap or expensive. A platform is basically useless for trading options without this indication obviously.
I don't think you understand, @drywin . You can calculate IV and IVR on the platform today. Quantconnect supports this. This ticket is just about making it easier to do so.
Dynamic history request option greeks should be possible relatively easily now -
- Recent work making option greeks and IV work in a classic AddOption request should be portable and work on history requests with some review.
- Reuse the fictional security object created for the history request (and the IVolatilityModel on the OptionSecurity object)
- Update SubscriptionDataReaderHistoryProvider L 108 to create an Option instead of a Security.
- Potentially do this via the SecurityService
The ideal core work of work would be to reprocess with the most popular greeks ready.
Excited to see activity around this! 🤞
-
Create the 5 Greeks/IV indicators.
-
Profiling Python options algorithm
-
Default to the daily universe instead of the current minutely reselection.
-
Use indicators to standardize to a typical daily universe dataset, underlying price, contract strike/expiry/prices/volumes, and greeks recalculated. Underlying could just be the first row to reduce duplication.
Small update for everyone; we worked January-March creating the option greeks as technical indicators and then doing studies to compare the outputs with popular third party sources. We were able to perfect our open-source variants and will use those technical indicators to pre-process the historical data greeks.
The pre-processing step is next on the cards; then loading it into LEAN for things like history calls or easily using it in universe filters.
We're in a maintenance sprint at the moment catching up on bugs, libraries, and small polish features but will get back to this superhero community project later in April.
This is great news. Thanks for the update!
On Tue, Apr 2, 2024, 1:34 PM Jared @.***> wrote:
Small update for everyone; we worked January-March creating the option greeks as technical indicators and then doing studies to compare the outputs with popular third party sources. We were able to perfect our open-source variants and will use those technical indicators to pre-process the historical data greeks.
The pre-processing step is next on the cards; then loading it into LEAN for things like history calls or easily using it in universe filters.
We're in a maintenance sprint at the moment catching up on bugs, libraries, and small polish features but will get back to this superhero community project later in April.
— Reply to this email directly, view it on GitHub https://github.com/QuantConnect/Lean/issues/3083#issuecomment-2033044086, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABPFFRBRXOGQACS2MNVLIL3Y3MI7DAVCNFSM4HFWW2YKU5DIOJSWCZC7NNSXTN2JONZXKZKDN5WW2ZLOOQ5TEMBTGMYDINBQHA3A . You are receiving this because you commented.Message ID: @.***>