|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.ftlabs.fisa.calc.AbstractCalculator
com.ftlabs.fisa.calc.MultipleCashFlowCalculator
com.ftlabs.fisa.calc.MultiplePeriodCalculator
com.ftlabs.fisa.calc.FixedInterestRateCalculator
public class FixedInterestRateCalculator
| Field Summary | |
|---|---|
protected int |
cashFlowCount
|
protected double |
interestRate
|
protected double |
taxAdjustedInterestRate
|
protected double |
taxAdjustedRedemptionValue
|
| Fields inherited from class com.ftlabs.fisa.calc.MultiplePeriodCalculator |
|---|
act_df, act_ldf, aif, df, fcf, lcf, ldf |
| Fields inherited from class com.ftlabs.fisa.calc.MultipleCashFlowCalculator |
|---|
eomAdjust, interestFrequency, nextCouponDate, parValue, redemption, settlementDate |
| Constructor Summary | |
|---|---|
protected |
FixedInterestRateCalculator()
|
|
FixedInterestRateCalculator(FISADate settlementDate,
Redemption redemption,
double parValue,
double interestRate,
DayCountBasis dayCountBasis,
int interestFrequency,
boolean eomAdjust,
FISADate datedDate,
FISADate firstInterestDate)
|
|
FixedInterestRateCalculator(FISADate settlementDate,
Redemption redemption,
double parValue,
double interestRate,
DayCountBasis dayCountBasis,
int interestFrequency,
boolean eomAdjust,
FISADate datedDate,
FISADate firstInterestDate,
boolean useFullPrice)
|
| Method Summary | |
|---|---|
Analytics |
calculate(AnalyticValueType givenType,
double givenValue)
Calculate an Analytics object using the provided
AnalyticValueType and value. |
double |
calculateAccruedInterest()
Calculate the accrued interest to the settlement date. |
double |
calculateCurrentYield(double price)
Calculate current yield for the given price. |
double |
calculateEstimatedConvexity(double pv1b,
double price,
double yield)
Calculate the estimated convexity. |
double |
calculatePeriodicYield(double price)
Calculate a periodic discounted cash flow yield for use with convexity/duration methods. |
double |
calculatePrice(double yield)
Calculate price for the given yield. |
double |
calculatePriceValue1BP(double price,
double yield)
Calculate the average price value obtained by varying the yield up and down one basis point. |
double |
calculateYield(double price)
Calculate yield for the given price. |
int |
getCashFlowCount()
Get the number of cashflows within the supported settlement to Redemption period. |
double |
getInterest(int cashFlowIndex)
Get the interest to be paid for a particular cashflow, as specified by cashFlowIndex. |
void |
setValues(FISADate settlementDate,
Redemption redemption,
double parValue,
double interestRate,
DayCountBasis dayCountBasis,
int interestFrequency,
boolean eomAdjust,
FISADate datedDate,
FISADate firstInterestDate)
|
void |
setValues(FISADate settlementDate,
Redemption redemption,
double parValue,
double interestRate,
DayCountBasis dayCountBasis,
int interestFrequency,
boolean eomAdjust,
FISADate datedDate,
FISADate firstInterestDate,
boolean useFullPrice)
|
| Methods inherited from class com.ftlabs.fisa.calc.MultiplePeriodCalculator |
|---|
getPeriodicTimeToFlow, getTimeToFlow, setValues |
| Methods inherited from class com.ftlabs.fisa.calc.AbstractCalculator |
|---|
calculateApproximateYield, calculateMPCIPrice, calculateSPSIPrice, calculateSPSIYield, calculateTotalInterestFlows |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected double interestRate
protected int cashFlowCount
protected double taxAdjustedInterestRate
protected double taxAdjustedRedemptionValue
| Constructor Detail |
|---|
protected FixedInterestRateCalculator()
public FixedInterestRateCalculator(FISADate settlementDate,
Redemption redemption,
double parValue,
double interestRate,
DayCountBasis dayCountBasis,
int interestFrequency,
boolean eomAdjust,
FISADate datedDate,
FISADate firstInterestDate)
throws CalculationException
CalculationException
public FixedInterestRateCalculator(FISADate settlementDate,
Redemption redemption,
double parValue,
double interestRate,
DayCountBasis dayCountBasis,
int interestFrequency,
boolean eomAdjust,
FISADate datedDate,
FISADate firstInterestDate,
boolean useFullPrice)
throws CalculationException
CalculationException| Method Detail |
|---|
public void setValues(FISADate settlementDate,
Redemption redemption,
double parValue,
double interestRate,
DayCountBasis dayCountBasis,
int interestFrequency,
boolean eomAdjust,
FISADate datedDate,
FISADate firstInterestDate)
throws CalculationException
CalculationException
public void setValues(FISADate settlementDate,
Redemption redemption,
double parValue,
double interestRate,
DayCountBasis dayCountBasis,
int interestFrequency,
boolean eomAdjust,
FISADate datedDate,
FISADate firstInterestDate,
boolean useFullPrice)
throws CalculationException
CalculationException
public double calculateCurrentYield(double price)
throws CalculationException
Calculator
price - price
CalculationException
public double calculateYield(double price)
throws CalculationException
Calculator
price - price
CalculationException
public double calculatePrice(double yield)
throws CalculationException
Calculator
yield - yield
CalculationException
public double calculateAccruedInterest()
throws CalculationException
Calculator
CalculationExceptionpublic int getCashFlowCount()
CalculatorRedemption period.
Redemption period.public double getInterest(int cashFlowIndex)
Calculator
cashFlowIndex - The cashflow index. cashFlowIndex is zero based
and must be a number from 0 to getCashFlowCount() - 1.
public double calculatePeriodicYield(double price)
throws CalculationException
Calculator
price - the price.
CalculationException
public double calculatePriceValue1BP(double price,
double yield)
throws CalculationException
Calculator
CalculationException
public double calculateEstimatedConvexity(double pv1b,
double price,
double yield)
throws CalculationException
Calculator
pv1b - The average price value obtained by varying the yield up
and down one basis point, as returned by the calculatePriceValue1BP
method.price - the price.yield - the yield.
CalculationException
public Analytics calculate(AnalyticValueType givenType,
double givenValue)
throws CalculationException
CalculatorAnalytics object using the provided
AnalyticValueType and value.
givenType - The AnalyticValueType of the givenValue.givenValue - The value to calculate the Analytics from.
CalculationException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||