Package org.drip.state.csa
Class MultilateralBasisCurve
java.lang.Object
org.drip.state.csa.MultilateralBasisCurve
- All Implemented Interfaces:
CashFlowEstimator
,DiscountFactorEstimator
public class MultilateralBasisCurve extends java.lang.Object implements CashFlowEstimator
MultilateralBasisCurve implements the CSA Cash Rate Curve as a Basis over an Overnight Curve. It
exports the following Functionality:
- Retrieve the Overnight Curve
- Retrieve the Basis to the Overnight Curve
Module | Product Core Module |
Library | Fixed Income Analytics |
Project | Latent State Inference and Creation Utilities |
Package | Credit Support Annex Latent State |
- Author:
- Lakshmi Krishnamurthy
-
Constructor Summary
Constructors Constructor Description MultilateralBasisCurve()
-
Method Summary
Modifier and Type Method Description double
basis()
Retrieve the Basis to the Overnight Curvedouble
df(int date)
Calculate the Discount Factor to the given Datedouble
df(java.lang.String tenor)
Calculate the Discount Factor to the given Tenordouble
df(JulianDate date)
Calculate the discount factor to the given datedouble
effectiveDF(int date1, int date2)
Compute the time-weighted discount factor between 2 datesdouble
effectiveDF(java.lang.String tenor1, java.lang.String tenor2)
Compute the time-weighted discount factor between 2 tenorsdouble
effectiveDF(JulianDate date1, JulianDate date2)
Compute the time-weighted discount factor between 2 datesJulianDate
epoch()
Retrieve the Starting (Epoch) DateMergedDiscountForwardCurve
overnightCurve()
Retrieve the Overnight Curvedouble
rate(int date)
Calculate the Cash Flow Rate Effective to the given Datedouble
rate(int date1, int date2)
Calculate the Cash Flow Rate Effective between the Datesdouble
rate(java.lang.String tenor)
Calculate the Cash Flow Rate Effective to the given Tenordouble
rate(java.lang.String tenor1, java.lang.String tenor2)
Calculate the Cash Flow Rate Effective between the Tenorsdouble
rate(JulianDate date)
Calculate the Cash Flow Rate Effective to the given datedouble
rate(JulianDate date1, JulianDate date2)
Calculate the Cash Flow Rate Effective between the DatesMethods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Constructor Details
-
MultilateralBasisCurve
public MultilateralBasisCurve()
-
-
Method Details
-
overnightCurve
Retrieve the Overnight Curve- Returns:
- The Overnight Curve
-
basis
public double basis()Retrieve the Basis to the Overnight Curve- Returns:
- The Basis to the Overnight Curve
-
epoch
Description copied from interface:DiscountFactorEstimator
Retrieve the Starting (Epoch) Date- Specified by:
epoch
in interfaceDiscountFactorEstimator
- Returns:
- The Starting Date
-
df
public double df(int date) throws java.lang.ExceptionDescription copied from interface:DiscountFactorEstimator
Calculate the Discount Factor to the given Date- Specified by:
df
in interfaceDiscountFactorEstimator
- Parameters:
date
- Date- Returns:
- Discount Factor
- Throws:
java.lang.Exception
- Thrown if the Discount Factor cannot be calculated
-
df
Description copied from interface:DiscountFactorEstimator
Calculate the discount factor to the given date- Specified by:
df
in interfaceDiscountFactorEstimator
- Parameters:
date
- Date- Returns:
- Discount factor
- Throws:
java.lang.Exception
- Thrown if the discount factor cannot be calculated
-
df
public double df(java.lang.String tenor) throws java.lang.ExceptionDescription copied from interface:DiscountFactorEstimator
Calculate the Discount Factor to the given Tenor- Specified by:
df
in interfaceDiscountFactorEstimator
- Parameters:
tenor
- Tenor- Returns:
- Discount factor
- Throws:
java.lang.Exception
- Thrown if the Discount Factor cannot be calculated
-
effectiveDF
public double effectiveDF(int date1, int date2) throws java.lang.ExceptionDescription copied from interface:DiscountFactorEstimator
Compute the time-weighted discount factor between 2 dates- Specified by:
effectiveDF
in interfaceDiscountFactorEstimator
- Parameters:
date1
- First Datedate2
- Second Date- Returns:
- Discount Factor
- Throws:
java.lang.Exception
- Thrown if the discount factor cannot be calculated
-
effectiveDF
Description copied from interface:DiscountFactorEstimator
Compute the time-weighted discount factor between 2 dates- Specified by:
effectiveDF
in interfaceDiscountFactorEstimator
- Parameters:
date1
- First Datedate2
- Second Date- Returns:
- Discount Factor
- Throws:
java.lang.Exception
- Thrown if the discount factor cannot be calculated
-
effectiveDF
public double effectiveDF(java.lang.String tenor1, java.lang.String tenor2) throws java.lang.ExceptionDescription copied from interface:DiscountFactorEstimator
Compute the time-weighted discount factor between 2 tenors- Specified by:
effectiveDF
in interfaceDiscountFactorEstimator
- Parameters:
tenor1
- First Datetenor2
- Second Date- Returns:
- Discount Factor
- Throws:
java.lang.Exception
- Thrown if the discount factor cannot be calculated
-
rate
public double rate(int date) throws java.lang.ExceptionDescription copied from interface:CashFlowEstimator
Calculate the Cash Flow Rate Effective to the given Date- Specified by:
rate
in interfaceCashFlowEstimator
- Parameters:
date
- Date- Returns:
- The Cash Flow Rate
- Throws:
java.lang.Exception
- Thrown if the Cash Flow Rate cannot be calculated
-
rate
Description copied from interface:CashFlowEstimator
Calculate the Cash Flow Rate Effective to the given date- Specified by:
rate
in interfaceCashFlowEstimator
- Parameters:
date
- Date- Returns:
- The Cash Flow Rate
- Throws:
java.lang.Exception
- Thrown if the Cash Flow Rate cannot be Calculated
-
rate
public double rate(java.lang.String tenor) throws java.lang.ExceptionDescription copied from interface:CashFlowEstimator
Calculate the Cash Flow Rate Effective to the given Tenor- Specified by:
rate
in interfaceCashFlowEstimator
- Parameters:
tenor
- Tenor- Returns:
- The Cash Flow Rate
- Throws:
java.lang.Exception
- Thrown if the Cash Flow Rate cannot be calculated
-
rate
public double rate(int date1, int date2) throws java.lang.ExceptionDescription copied from interface:CashFlowEstimator
Calculate the Cash Flow Rate Effective between the Dates- Specified by:
rate
in interfaceCashFlowEstimator
- Parameters:
date1
- Date #1date2
- Date #2- Returns:
- The Cash Flow Rate
- Throws:
java.lang.Exception
- Thrown if the Cash Flow Rate cannot be calculated
-
rate
Description copied from interface:CashFlowEstimator
Calculate the Cash Flow Rate Effective between the Dates- Specified by:
rate
in interfaceCashFlowEstimator
- Parameters:
date1
- Date #1date2
- Date #2- Returns:
- The Cash Flow Rate
- Throws:
java.lang.Exception
- Thrown if the Cash Flow Rate cannot be calculated
-
rate
public double rate(java.lang.String tenor1, java.lang.String tenor2) throws java.lang.ExceptionDescription copied from interface:CashFlowEstimator
Calculate the Cash Flow Rate Effective between the Tenors- Specified by:
rate
in interfaceCashFlowEstimator
- Parameters:
tenor1
- Tenor #1tenor2
- Tenor #2- Returns:
- The Cash Flow Rate
- Throws:
java.lang.Exception
- Thrown if the Cash Flow Rate cannot be calculated
-