com.ftlabs.fisa.calc
Class QuoteAnalytics

java.lang.Object
  extended by com.ftlabs.fisa.calc.QuoteAnalytics
All Implemented Interfaces:
Analytics, java.io.Serializable

public class QuoteAnalytics
extends java.lang.Object
implements Analytics

Contains Analytics to all redemptions for the Security from which it was created.

See Also:
Serialized Form

Constructor Summary
QuoteAnalytics(double price, Calculator[] calculators)
           
 
Method Summary
 double getAccruedInterest()
          Get the accrued interest.
 Analytics getAnalytics(Redemption redemption)
           
 double getAnalyticValue(AnalyticValueType type)
          Get an analytic value of the provided AnalyticValueType.
 Calculator getCalculator()
          Get the calculator that was used to create this Analytics object.
 double getConvexity()
          Get the convexity.
 double getEstimatedConvexity()
          Get the estimated convexity.
 double getEstimatedMacaulayDuration()
          Get the estimated Macaulay duration.
 double getEstimatedModifiedDuration()
          Get the estimated modified duration.
 double getInterestOnInterest()
          Get interest on interest using an assumed reinvestment yield that is equal to yield.
 double getInterestOnInterest(double reinvestmentYield)
          Get interest on interest.
 Analytics getLowestYieldAnalytics()
           
 double getMacaulayDuration()
          Get the Macaulay duration
 double getModifiedDuration()
          Get the modified duration
 double getPrice()
          Get the price.
 double getPriceValue1BP()
          Get the average price value obtained by varying the yield up and down by one basis point.
 Redemption getRedemption()
          Get the Redemption object to which this Analytics object was calculated.
 Redemption getRedemption(int index)
           
 int getRedemptionCount()
           
 double getTotalInterestFlows()
          Get the total interest flows.
 double getYield()
          Get the yield.
 double getYieldValue1_32()
          Get the average yield value obtained by varying the price up and down by 1/32.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

QuoteAnalytics

public QuoteAnalytics(double price,
                      Calculator[] calculators)
Method Detail

getLowestYieldAnalytics

public Analytics getLowestYieldAnalytics()
                                  throws CalculationException
Throws:
CalculationException

getAnalytics

public Analytics getAnalytics(Redemption redemption)
                       throws CalculationException
Throws:
CalculationException

getRedemption

public Redemption getRedemption()
Description copied from interface: Analytics
Get the Redemption object to which this Analytics object was calculated.

Specified by:
getRedemption in interface Analytics
Returns:
the Redemption object to which this Analytics object is calculated.

getCalculator

public Calculator getCalculator()
Description copied from interface: Analytics
Get the calculator that was used to create this Analytics object.

Specified by:
getCalculator in interface Analytics
Returns:
the calculator that was used to create this Analtyics object.

getRedemptionCount

public int getRedemptionCount()

getRedemption

public Redemption getRedemption(int index)

getPrice

public double getPrice()
                throws CalculationException
Description copied from interface: Analytics
Get the price.

Specified by:
getPrice in interface Analytics
Returns:
price.
Throws:
CalculationException

getYield

public double getYield()
                throws CalculationException
Description copied from interface: Analytics
Get the yield.

Specified by:
getYield in interface Analytics
Returns:
yield.
Throws:
CalculationException

getMacaulayDuration

public double getMacaulayDuration()
                           throws CalculationException
Description copied from interface: Analytics
Get the Macaulay duration

Specified by:
getMacaulayDuration in interface Analytics
Returns:
Macaulay duration.
Throws:
CalculationException

getModifiedDuration

public double getModifiedDuration()
                           throws CalculationException
Description copied from interface: Analytics
Get the modified duration

Specified by:
getModifiedDuration in interface Analytics
Returns:
modified duration.
Throws:
CalculationException

getConvexity

public double getConvexity()
                    throws CalculationException
Description copied from interface: Analytics
Get the convexity.

Specified by:
getConvexity in interface Analytics
Returns:
convexity.
Throws:
CalculationException

getPriceValue1BP

public double getPriceValue1BP()
                        throws CalculationException
Description copied from interface: Analytics
Get the average price value obtained by varying the yield up and down by one basis point.

Specified by:
getPriceValue1BP in interface Analytics
Returns:
the average price value obtained by varying the yield up and down by one basis point.
Throws:
CalculationException

getYieldValue1_32

public double getYieldValue1_32()
                         throws CalculationException
Description copied from interface: Analytics
Get the average yield value obtained by varying the price up and down by 1/32.

Specified by:
getYieldValue1_32 in interface Analytics
Returns:
the average yield value obtained by varying the price up and down by 1/32.
Throws:
CalculationException

getEstimatedMacaulayDuration

public double getEstimatedMacaulayDuration()
                                    throws CalculationException
Description copied from interface: Analytics
Get the estimated Macaulay duration.

Specified by:
getEstimatedMacaulayDuration in interface Analytics
Returns:
estimated Macaulay duration.
Throws:
CalculationException

getEstimatedModifiedDuration

public double getEstimatedModifiedDuration()
                                    throws CalculationException
Description copied from interface: Analytics
Get the estimated modified duration.

Specified by:
getEstimatedModifiedDuration in interface Analytics
Returns:
estimated modified duration.
Throws:
CalculationException

getEstimatedConvexity

public double getEstimatedConvexity()
                             throws CalculationException
Description copied from interface: Analytics
Get the estimated convexity.

Specified by:
getEstimatedConvexity in interface Analytics
Returns:
estimated convexity.
Throws:
CalculationException

getAccruedInterest

public double getAccruedInterest()
                          throws CalculationException
Description copied from interface: Analytics
Get the accrued interest.

Specified by:
getAccruedInterest in interface Analytics
Returns:
accrued interest.
Throws:
CalculationException

getTotalInterestFlows

public double getTotalInterestFlows()
                             throws CalculationException
Description copied from interface: Analytics
Get the total interest flows.

Specified by:
getTotalInterestFlows in interface Analytics
Returns:
the total interest flows.
Throws:
CalculationException

getInterestOnInterest

public double getInterestOnInterest()
                             throws CalculationException
Description copied from interface: Analytics
Get interest on interest using an assumed reinvestment yield that is equal to yield.

Specified by:
getInterestOnInterest in interface Analytics
Returns:
interest on interest
Throws:
CalculationException

getInterestOnInterest

public double getInterestOnInterest(double reinvestmentYield)
                             throws CalculationException
Description copied from interface: Analytics
Get interest on interest.

Specified by:
getInterestOnInterest in interface Analytics
Returns:
interest on interest
Throws:
CalculationException

getAnalyticValue

public double getAnalyticValue(AnalyticValueType type)
                        throws CalculationException
Description copied from interface: Analytics
Get an analytic value of the provided AnalyticValueType.

Specified by:
getAnalyticValue in interface Analytics
Parameters:
type - the type of analytic value to get
Returns:
yield.
Throws:
CalculationException