Package org.drip.param.market
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.
- Module = Product Core Module
- Library = Fixed Income Analytics
- Project = Product Cash Flow, Valuation, Market, Pricing, and Quoting Parameters
- Package = Curves Surfaces Quotes Fixings Container
- Author:
- Lakshmi Krishnamurthy
-
Field Summary
Fields Modifier and Type Field Description static int
CC_BASE
CC Scenario Basestatic int
CC_FLAT_DN
CC Scenario Parallel Downstatic int
CC_FLAT_UP
CC Scenario Parallel Upstatic int
CC_RR_FLAT_DN
CC Scenario Recovery Parallel Downstatic int
CC_RR_FLAT_UP
CC Scenario Recovery Parallel Upstatic int
CC_TENOR_DN
CC Scenario Tenor Downstatic int
CC_TENOR_UP
CC Scenario Tenor Up -
Constructor Summary
Constructors Constructor Description CreditCurveScenarioContainer(CalibratableComponent[] aCalibInst, double dblCouponBump, double dblRecoveryBump)
Construct CreditCurveScenarioContainer from the array of calibration instruments, the coupon bump parameter, and the recovery bump parameter -
Method Summary
Modifier and Type Method Description CreditCurve
base()
Return the base credit curveCreditCurve
bumpDown()
Return the bump Down credit curveCreditCurve
bumpRecoveryDown()
Return the recovery bump Down credit curveCreditCurve
bumpRecoveryUp()
Return the recovery bump up credit curveCreditCurve
bumpUp()
Return the bump up credit curveboolean
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 parametersboolean
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 specifiedCaseInsensitiveTreeMap<CreditCurve>
custom()
Return the Custom credit curve mapCaseInsensitiveTreeMap<CreditCurve>
tenorBumpDown()
Return the tenor bump Down credit curve mapCaseInsensitiveTreeMap<CreditCurve>
tenorBumpUp()
Return the tenor bump up credit curve mapMethods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Field Details
-
CC_BASE
public static final int CC_BASECC Scenario Base- See Also:
- Constant Field Values
-
CC_FLAT_UP
public static final int CC_FLAT_UPCC Scenario Parallel Up- See Also:
- Constant Field Values
-
CC_FLAT_DN
public static final int CC_FLAT_DNCC Scenario Parallel Down- See Also:
- Constant Field Values
-
CC_TENOR_UP
public static final int CC_TENOR_UPCC Scenario Tenor Up- See Also:
- Constant Field Values
-
CC_TENOR_DN
public static final int CC_TENOR_DNCC Scenario Tenor Down- See Also:
- Constant Field Values
-
CC_RR_FLAT_UP
public static final int CC_RR_FLAT_UPCC Scenario Recovery Parallel Up- See Also:
- Constant Field Values
-
CC_RR_FLAT_DN
public static final int CC_RR_FLAT_DNCC Scenario Recovery Parallel Down- See Also:
- Constant Field Values
-
-
Constructor Details
-
CreditCurveScenarioContainer
public CreditCurveScenarioContainer(CalibratableComponent[] aCalibInst, double dblCouponBump, double dblRecoveryBump) throws java.lang.ExceptionConstruct CreditCurveScenarioContainer from the array of calibration instruments, the coupon bump parameter, and the recovery bump parameter- Parameters:
aCalibInst
- Array of calibration instrumentsdblCouponBump
- Coupon BumpdblRecoveryBump
- 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 NamevalParams
- ValuationParamsdc
- Base Discount Curvegc
- Govvie CurveastrCalibMeasure
- Matched array of Calibration measuresadblQuote
- Matched array of QuotesdblRecovery
- Curve Recoverylsfc
- Latent State Fixings Containervcp
- Valuation Customization ParametersbFlat
- Whether the calibration is to a flat curveiScenario
- 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 NamestrCustomName
- Scenario NamevalParams
- Valuation Parametersdc
- Discount Curvegc
- Govvie CurveastrCalibMeasure
- Array of calibration measuresadblQuote
- Double array of input quotesdblRecovery
- Recovery Ratelsfc
- Latent State Fixings Containervcp
- Valuation Customization ParametersbFlat
- Whether the calibration is flatrvtpDC
- Node Tweak Parameters for the Base Discount CurvervtpTSY
- Node Tweak Parameters for the TSY Discount CurvervtpCC
- Node Tweak Parameters for the Credit Curve- Returns:
- True - Credit Curve successfully created
-
base
Return the base credit curve- Returns:
- The base credit curve
-
bumpUp
Return the bump up credit curve- Returns:
- The Bumped up credit curve
-
bumpDown
Return the bump Down credit curve- Returns:
- The Bumped Down credit curve
-
bumpRecoveryUp
Return the recovery bump up credit curve- Returns:
- The Recovery Bumped up credit curve
-
bumpRecoveryDown
Return the recovery bump Down credit curve- Returns:
- The Recovery Bumped Down credit curve
-
tenorBumpUp
Return the tenor bump up credit curve map- Returns:
- The Tenor Bumped up credit curve Map
-
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
-