A tutorial notebook that examines how options data can be scraped using Python and how that data can be implemented for trading strategies.
This walkthrough starts by first scraping put and call pricing data for commonly-traded index equities (SPY, QQQ, etc.). After the data is scraped, pandas DataFrames are put together for puts and calls. From there, we explore how to turn that code into a Class and expand upon it to implement trading strategies such as credit spreads and iron condors. Finally, we run through examples before delving into some analysis that examines the efficacies of potential strategies. By the end of this notebook, I hope that it is clearly conveyed how options can be traded in an everyday account to augment a portfolio and how such strategies would be implmented and analyzed with Python.
The table of contents, which can be found inside, is as follows:
-
Web-scraping the option chain
-
Other Necessary Functions/Concepts
-
Covered Call Example
-
Defining our strategy class
-
Credit Spread Example
-
Monte Carlo analysis
-
Conclusion
The full repo can be found here: https://github.com/lbianculli/options