Пример #1
0
  // calibrated sum PV01 for one scenario
  MultiCurrencyAmount pv01CalibratedSum(ResolvedDsfTrade trade, RatesProvider ratesProvider) {

    PointSensitivities pointSensitivity = tradePricer.presentValueSensitivity(trade, ratesProvider);
    return ratesProvider
        .parameterSensitivity(pointSensitivity)
        .total()
        .multipliedBy(ONE_BASIS_POINT);
  }
Пример #2
0
  // market quote bucketed PV01 for one scenario
  CurrencyParameterSensitivities pv01MarketQuoteBucketed(
      ResolvedDsfTrade trade, RatesProvider ratesProvider) {

    PointSensitivities pointSensitivity = tradePricer.presentValueSensitivity(trade, ratesProvider);
    CurrencyParameterSensitivities parameterSensitivity =
        ratesProvider.parameterSensitivity(pointSensitivity);
    return MARKET_QUOTE_SENS
        .sensitivity(parameterSensitivity, ratesProvider)
        .multipliedBy(ONE_BASIS_POINT);
  }