Class CreditCurveScenarioContainer

java.lang.Object
org.drip.param.market.CreditCurveScenarioContainer

public class CreditCurveScenarioContainer
extends java.lang.Object
CreditCurveScenarioContainer contains the place holder for the bump parameters and the curves for the different credit curve scenarios. Contains the spread and the recovery bumps, and the credit curve scenario generator object that wraps the calibration instruments. It also contains the base credit curve, spread bumped up/down credit curves, recovery bumped up/down credit curves, and the tenor mapped up/down credit curves.

Author:
Lakshmi Krishnamurthy
  • Field Details

    • CC_BASE

      public static final int CC_BASE
      CC Scenario Base
      See Also:
      Constant Field Values
    • CC_FLAT_UP

      public static final int CC_FLAT_UP
      CC Scenario Parallel Up
      See Also:
      Constant Field Values
    • CC_FLAT_DN

      public static final int CC_FLAT_DN
      CC Scenario Parallel Down
      See Also:
      Constant Field Values
    • CC_TENOR_UP

      public static final int CC_TENOR_UP
      CC Scenario Tenor Up
      See Also:
      Constant Field Values
    • CC_TENOR_DN

      public static final int CC_TENOR_DN
      CC Scenario Tenor Down
      See Also:
      Constant Field Values
    • CC_RR_FLAT_UP

      public static final int CC_RR_FLAT_UP
      CC Scenario Recovery Parallel Up
      See Also:
      Constant Field Values
    • CC_RR_FLAT_DN

      public static final int CC_RR_FLAT_DN
      CC Scenario Recovery Parallel Down
      See Also:
      Constant Field Values
  • Constructor Details

    • CreditCurveScenarioContainer

      public CreditCurveScenarioContainer​(CalibratableComponent[] aCalibInst, double dblCouponBump, double dblRecoveryBump) throws java.lang.Exception
      Construct CreditCurveScenarioContainer from the array of calibration instruments, the coupon bump parameter, and the recovery bump parameter
      Parameters:
      aCalibInst - Array of calibration instruments
      dblCouponBump - Coupon Bump
      dblRecoveryBump - Recovery Bump
      Throws:
      java.lang.Exception - Thrown if inputs are invalid
  • Method Details

    • cookScenarioCC

      public boolean cookScenarioCC​(java.lang.String strName, ValuationParams valParams, MergedDiscountForwardCurve dc, GovvieCurve gc, java.lang.String[] astrCalibMeasure, double[] adblQuote, double dblRecovery, LatentStateFixingsContainer lsfc, ValuationCustomizationParams vcp, boolean bFlat, int iScenario)
      Cook and save the credit curves corresponding to the scenario specified
      Parameters:
      strName - Credit Curve Name
      valParams - ValuationParams
      dc - Base Discount Curve
      gc - Govvie Curve
      astrCalibMeasure - Matched array of Calibration measures
      adblQuote - Matched array of Quotes
      dblRecovery - Curve Recovery
      lsfc - Latent State Fixings Container
      vcp - Valuation Customization Parameters
      bFlat - Whether the calibration is to a flat curve
      iScenario - One of the values in the CC_ enum listed above.
      Returns:
      Success (true), failure (false)
    • cookCustomCC

      public boolean cookCustomCC​(java.lang.String strName, java.lang.String strCustomName, ValuationParams valParams, MergedDiscountForwardCurve dc, GovvieCurve gc, java.lang.String[] astrCalibMeasure, double[] adblQuote, double dblRecovery, LatentStateFixingsContainer lsfc, ValuationCustomizationParams vcp, boolean bFlat, ManifestMeasureTweak rvtpDC, ManifestMeasureTweak rvtpTSY, ManifestMeasureTweak rvtpCC)
      Cook the credit curve according to the desired tweak parameters
      Parameters:
      strName - Scenario Credit Curve Name
      strCustomName - Scenario Name
      valParams - Valuation Parameters
      dc - Discount Curve
      gc - Govvie Curve
      astrCalibMeasure - Array of calibration measures
      adblQuote - Double array of input quotes
      dblRecovery - Recovery Rate
      lsfc - Latent State Fixings Container
      vcp - Valuation Customization Parameters
      bFlat - Whether the calibration is flat
      rvtpDC - Node Tweak Parameters for the Base Discount Curve
      rvtpTSY - Node Tweak Parameters for the TSY Discount Curve
      rvtpCC - Node Tweak Parameters for the Credit Curve
      Returns:
      True - Credit Curve successfully created
    • base

      public CreditCurve base()
      Return the base credit curve
      Returns:
      The base credit curve
    • bumpUp

      public CreditCurve bumpUp()
      Return the bump up credit curve
      Returns:
      The Bumped up credit curve
    • bumpDown

      public CreditCurve bumpDown()
      Return the bump Down credit curve
      Returns:
      The Bumped Down credit curve
    • bumpRecoveryUp

      public CreditCurve bumpRecoveryUp()
      Return the recovery bump up credit curve
      Returns:
      The Recovery Bumped up credit curve
    • bumpRecoveryDown

      public CreditCurve bumpRecoveryDown()
      Return the recovery bump Down credit curve
      Returns:
      The Recovery Bumped Down credit curve
    • tenorBumpUp

      public CaseInsensitiveTreeMap<CreditCurve> tenorBumpUp()
      Return the tenor bump up credit curve map
      Returns:
      The Tenor Bumped up credit curve Map
    • tenorBumpDown

      public CaseInsensitiveTreeMap<CreditCurve> tenorBumpDown()
      Return the tenor bump Down credit curve map
      Returns:
      The Tenor Bumped Down credit curve Map
    • custom

      Return the Custom credit curve map
      Returns:
      The Custom credit curve Map