Open interest data for option contracts
Author: Partha
Creation Date: 10/1/2019 4:02 AM
profile picture

Partha

#1
As a fidelity customer so I can access the option price and volume directly in WL but I don't know how to get the open interest..Is is possible to get the open interest on a particular options contract in WL ?
profile picture

Eugene

#2
No, it's highly unlikely that the open interest data is provided by the Fidelity static data provider.

You might want to look for a 3rd party data vendor, WebService or even a website which has such data and let us know if you're onto something.
profile picture

Partha

#3
Fidelity has all of this info on their website once you login...the problem is I cannot use this valuable info in strategy code...having both volume and open interest on options can be useful to get confirmation on signals based existing indicators in WL...attached snapson from fidelity site once I log in
profile picture

Eugene

#4
QUOTE:
Fidelity has all of this info on their website once you login

Fidelity login requirement makes it difficult as I don't have my own account there for development. Been there done that: Is ETF Bid / Ask data available in WL ?

Alternatives are appreciated.
profile picture

Partha

#5
these guys are the big daddy of options data...they provide data to fidelity..it is a paid service though

https://www.livevol.com/
profile picture

Eugene

#6
Sorry but signing agreements with a high priced feed goes far beyond the quick help I intended to provide. Will keep looking for and post here should I discover some decent source for parsing (preferably free).
profile picture

Partha

#7
Yahoo has the datafeed (delayed but it is OK)...maybe possible to parse this?

https://finance.yahoo.com/quote/TM/options?p=TM
profile picture

Eugene

#8
I was thinking of this as a backup source but Yahoo is OK:
https://www.barchart.com/stocks/quotes/AMD/options?expiration=2019-10-25&moneyness=allRows

Unlike its historical data download (tricky!), Yahoo's options page is easy to parse. Here's proof-of-concept. It doesn't attempt to parse, validate or process the raw text yet - just prints it out. Let me know if you need some of that and what exactly.

Prerequisites:

1. Requires Community Components or other extension installed that depends on having HtmlAgilityPack.dll
2. check System.Core and System.Xml in the Editor (References... > .NET Framework), OK, Save.

CODE:
Please log in to see this code.
profile picture

Partha

#9
it is not working for me...I have the HtmlAgilityPack but it is underlined in red in the code...see the references in the attached snapshot
profile picture

Eugene

#10
It's a bug in 6.9.20, see here for workaround: WLP 6.9.20.7: New Editor has compiler error with LINQ methods

P.S. More 6.9.20 issues: List of WLP 6.9.20.7 Issues and Fixes

profile picture

Partha

#11
it works...thanks!!

By the way I requested fidelity to consider this as a standard feature as options volume and open interest can be used to confirm standard WL indicators buy and sell signals....they agreed with me and have passed on the suggestion to the software development team (I guess that is you guys :-)
profile picture

Eugene

#12
You're welcome.
profile picture

Eugene

#13
Latest and greatest. Reusable, robust parsing, uses global memory to cache web requests. Think I add it to Community Components.

Prerequisites:

1. Workaround for a bug in 6.9.20: WLP 6.9.20.7: New Editor has compiler error with LINQ methods
2. Check System.Core and System.Xml in the Editor (References... > .NET Framework), OK, Save.

CODE:
Please log in to see this code.
profile picture

Partha

#14
Cool stuff
profile picture

Cone

#15
+1
profile picture

Eugene

#16
@Partha

Added OpenInterestForOptions class to Community Components:

OpenInterestForOptions
profile picture

Partha

#17
Thanks Eugene
profile picture

Eugene

#18
You're welcome.
This website uses cookies to improve your experience. We'll assume you're ok with that, but you can opt-out if you wish (Read more).