# How to validate option greeks/implied volatility data calculated in-house using Black model on a mass scale in an automated fashion?

I have created a platform that computes implied volatility, option theo prices and greeks using Black 1976 model.

I use this platform to calculate above mentioned numbers for a variety of options traded across many different exchanges in real time.

I want to come up with a way to automatically test the sanity of the numbers I compute on historical data (I have close prices, tick by tick data for all products).

Some thoughts I have gathered to achieve this:

• Come up with a list of sanity checks such as delta of an even put-call portfolio should be close to zero. Payoff should be ~ (spot price - strike price) Can someone suggest me a list of similar checks I could evaluate my data on?

• Compare my numbers with a third party source. Does there exist one? I understand that these numbers depend on the model used,I only want my numbers to be in the ballpark. Some amount of error is permissible.

I am open to any other ideas that can help me test sanity automatically / semi-automatically (e.g. plotting graphs and analyzing them).

Another application of vol surfaces right here. A poor fit indicdates strongly the likelihood of bad data - particularly when the number of strikes is high as is the case for SPX.

Since you do not need a brilliant vol surface for pricing exotics, you needn't worry about smoothness at all points or arbitrage free considerations. A quick thing is to fit your vols to a piecewise continuous parabolic functional form. Something like this:

$$\sigma(k)=\sigma_\mathrm{atm}+\beta k+\alpha k^2$$

where $k=\mathrm{log}(K/F)$. I would fit the ATM by doing a similar parabolic fit on the strikes near the money and your ATM vol will be the intercept. Then you can fit the left side of the vol smile with the parabolic form above constrained so that the intercept is $\sigma_\mathrm{atm}$. In other words, fit

$$\sigma(k)-\sigma_\mathrm{atm}=\beta_L k+\alpha_L k^2$$

Then do the same thing on the right hand side:

$$\sigma(k)-\sigma_\mathrm{atm}=\beta_R k+\alpha_R k^2$$

This gives you 5 parameters for fitting a vol smile while only doing 3 regressions - very quick operations. The five parameters are $\sigma_\mathrm{atm}, \alpha_L,\beta_L,\alpha_R,\beta_R$.

These 5 parameters can actually fit the data impressively well when the data is good and bid ask is not ridiculously wide (outside of the W shaped vol "smiles" user @LocalVolatility schooled me on). Although this is not a linear regression, I still like to use the $R^2$ formula to compare my fitted vols to the input vols. For a ticker like SPX, you will typically see an $R^2$ of 99.8 - the fit is extremely good. I also like to look at what I call the $L^1$, $L^2$, and $L^\infty$ errors for my fits. $L^1$ error is the sum of the absolute errors in vol space. $L^2$ error is the square root of the sum square errprs in the fit and $L^\infty$ error is the maximum error in the fit. On top of that, counting the number of times missing bid ask, the vega weighted number of times missing bid ask where vega is based on the vol from the fitted smile and the $L^1$ distance from the bid ask spread - i.e. the sum absolute difference between the fitted vols and the bid ask spread - if inside of the bid ask spread the distance is zero. I use a combination of all of these measures to assess my data quality along with some other tricks.

You also have the advantage of looking at tick data - so you can see a time series of these error metrics. A sudden drastic change could be an alert requiring intervention - but at this point handling the details are up to you.

Some additional work may be required for American options since put/call vols are not required to be the same....and if using single stocks, borrow costs can be annoying...but I don't have time to discuss those detail right now.

PS - be sure to discard strikes that are less than 1 or 2 delta from such a fit - maybe even less than 5 delta - depending on what you need. For SPX going all the way to 1 delta options is fine - but going past that, you see a lot of noise on the wings. I do a lot of work cleaning up the wings that I have not discussed here - I generally try to tighten up the bid ask when I get to the wings so that the put/call prices are monotonic - it is a pain in the butt, but keeps things much cleaner in the long run.

• Hi, thanks for taking time to write a detailed reply. While it sounds pretty interesting, but I don't think it is what I am looking for. My original algorithm to compute implied vol and then greeks is based on computing vol smile in a similar way to what you described above in the first place. So I need to find another different way to compute the same numbers in order to validate :) Any thoughts? – Saurabh Kumar May 18 '17 at 11:21
• The $R^2$ alone is usually a strong indicator data quality assuming you have at least 10-12 nicely spaced strikes. If it is an FX case where you usually only have 5 strikes, then it may be better to add some artifical points with Vanna Volga and then do a fit as I described above. For SPX, if your $R^2 \le 0.96$, and time to expiry is more than a week, it is very likely that there is problem data. Different tickers will have different $R^2$ benchmarks to use, but this single metric tells you a lot about your data quality. If your vols are good, so are the Greeks. – FinanceGuyThatCantCode May 18 '17 at 14:26