I am testing spline interpolation for volatility surface with Matlab griddedInterpolant function with spline as interpolation and extrapolation method.
Here is the original data I used to do interpolation.
I used tenor = 147 to test.Most of interpolated data are good. But there are still outliers such as the points at 70 and 85. And It seems the extrapolation result from matlab is not quite right.
something I did is not correct?
Here is my matlab code
data = xlsread('researchData.xlsx'); tenors = data(2:end,1); strikes = data(1,2:end); [tenors,strikes]=ndgrid(tenors,strikes); F = griddedInterpolant(tenors,strikes,data(2:end,2:end),'spline','spline'); targetStrike = [60,70,85,90,91,100,103,105,110,115,125,170]'; targettenor = ones(length(targetStrike),1) * 147; interpVol = F(targettenor,targetStrike); interpVol = interpVol';