Class SabrModelFitter


  • public final class SabrModelFitter
    extends SmileModelFitter<SabrFormulaData>
    SABR model fitter.

    Attempts to calibrate SABR model to the implied volatilities of European vanilla options, by minimizing the sum of squares between the market and model implied volatilities.

    All the options must be for the same expiry and (implicitly) on the same underlying.

    • Constructor Detail

      • SabrModelFitter

        public SabrModelFitter​(double forward,
                               DoubleArray strikes,
                               double timeToExpiry,
                               DoubleArray impliedVols,
                               DoubleArray error,
                               SabrVolatilityFormula sabrVolatilityFormula)
        Constructs SABR model fitter from forward, strikes, time to expiry, implied volatilities and error values.

        strikes, impliedVols and error should be the same length and ordered coherently.

        Parameters:
        forward - the forward value of the underlying
        strikes - the ordered values of strikes
        timeToExpiry - the time-to-expiry
        impliedVols - the market implied volatilities
        error - the 'measurement' error to apply to the market volatility of a particular option
        sabrVolatilityFormula - the volatility formula
      • SabrModelFitter

        public SabrModelFitter​(double forward,
                               DoubleArray strikes,
                               double timeToExpiry,
                               DoubleArray impliedVols,
                               DoubleArray error,
                               VolatilityFunctionProvider<SabrFormulaData> model)
        Constructs SABR model fitter from forward, strikes, time to expiry, implied volatilities and error values.

        strikes, impliedVols and error should be the same length and ordered coherently.

        Parameters:
        forward - the forward value of the underlying
        strikes - the ordered values of strikes
        timeToExpiry - the time-to-expiry
        impliedVols - the market implied volatilities
        error - the 'measurement' error to apply to the market volatility of a particular option
        model - the volatility function provider