I am trying to use QuantConnect to run some historical analysis, which involves comparison of skew (more specifically, $\frac{25\Delta\text{ put volatility} - 25\Delta\text{ call volatility}}{50\Delta\text{ call volatility}}$ à la Mixon. What troubles me is that I would find, in the data, calls and puts (of same expiry) with near-50 delta having wildly different implied volatilities, which violates put-call parity.

My Algorithm (which generates the data and calculates Greeks via setting option.PriceModel) is as follows. I am reluctant to run my own Greeks as it requires knowledge of future dividends at every time step. Not exactly sure where I am tripping up...

def Initialize(self):
    self.SetStartDate(2022, 1, 1)
    self.SetEndDate(2022, 6, 25)

    self._use_index_options = False

    # https://www.quantconnect.com/docs/v2/writing-algorithms/reality-modeling/options-models/pricing#04-Supported-Models
    if self._use_index_options:
        symbol = "SPX"
        underlying = self.AddIndex(symbol, Resolution.Daily).Symbol
        option = self.AddIndexOption(underlying, Resolution.Daily)
        option.PriceModel = OptionPriceModels.BlackScholes()
        symbol = "SPY"
        underlying = self.AddEquity(symbol, Resolution.Daily)
        option = self.AddOption(underlying, Resolution.Daily)
        option.PriceModel = OptionPriceModels.CrankNicolsonFD()
    self.option_symbol = option.Symbol
    self.Securities[symbol].VolatilityModel = StandardDeviationOfReturnsVolatilityModel(30, Resolution.Daily)

    option.SetFilter(-10, +10, 0, 180)
    self.SetWarmUp(30, Resolution.Daily)


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.