QuantConnect / Lean

Lean Algorithmic Trading Engine by QuantConnect (Python, C#)
https://lean.io
Apache License 2.0
9.88k stars 3.27k forks source link

Enable Greeks and Implied Vol. from Options History Request #3083

Open simonsonjack opened 5 years ago

simonsonjack commented 5 years ago

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

mcguirebc commented 4 years ago

Would love to see this feature!

JakeTheSnake3p0 commented 4 years ago

I'll second that. It would answer my question.

jgerardsimcock commented 4 years ago

Is there a way to contribute to this? If we fork LEAN and implement in Python will that be sufficient?

ikamanu commented 3 years ago

Any update on this?

petegordon commented 3 years ago

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!

ikamanu commented 3 years ago

This is very promising. Thank for sharing this.

mankan1 commented 3 years ago

Is this resolved? How to use it?

Kevin-Chen0 commented 3 years ago

Is there an update on this?

jaredbroad commented 3 years ago

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.

RyanTau commented 2 years ago

Been around 11 months, has there been any progress made with this?

dryqin commented 1 year ago

IV and IVR basically indicate if a contract is cheap or expensive. A platform is basically useless for trading options without this indication obviously.

ikamanu commented 1 year ago

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.

jaredbroad commented 1 year ago

Dynamic history request option greeks should be possible relatively easily now -

jaredbroad commented 1 year ago

The ideal core work of work would be to reprocess with the most popular greeks ready.

ikamanu commented 1 year ago

Excited to see activity around this! 🤞

jaredbroad commented 11 months ago
jaredbroad commented 7 months ago

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.

ikamanu commented 7 months ago

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: @.***>