# spline Interpolation on volatility surface not smooth

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'; • This doesn't look good, no. How did you create the plot? Mar 28, 2019 at 14:46
• @BobJansen I generated interpolated data in Matlab and scatter plot in Excel Mar 28, 2019 at 14:56
• Aha, I think it would be helpful if you show how you interpolated the data in MATLAB. Mar 28, 2019 at 15:09
• @BobJansen I just added my MATLAB code. Mar 28, 2019 at 15:19
• What else should your plot look like? Given your input data, which is matched by the spline, that is exactly what you would expect. So I guess you did nothing wrong with the interpolation. Maybe you should take another look at your input data especially the orange points at 170 and 70 look somewhat "wrong". And an extrapolation with splines is always problematic since it tends to show weird behavior like exploding values or even negative ones and offers posibilities for arbitrage. Maybe you could think about clamped splines. Mar 29, 2019 at 11:18