IndexMixin#

class rateslib.periods.IndexMixin#

Bases: object

Abstract base class to include methods and properties related to indexed Periods.

Attributes Summary

currency

index_base

index_fixings

index_lag

index_method

payment

real_cashflow

Methods Summary

cashflow([curve])

float, Dual or Dual2 : The calculated value from rate, dcf and notional, adjusted for the index.

index_ratio([curve])

Calculate the index ratio for the end date of the IndexPeriod.

npv([curve, disc_curve, fx, base, local])

Return the cashflows of the IndexPeriod.

Attributes Documentation

currency = ''#
index_base = 0#
index_fixings = 0#
index_lag = 0#
index_method = ''#
payment = datetime.datetime(1990, 1, 1, 0, 0)#
real_cashflow#

Methods Documentation

cashflow(curve=NoInput.blank)#

float, Dual or Dual2 : The calculated value from rate, dcf and notional, adjusted for the index.

index_ratio(curve=NoInput.blank)#

Calculate the index ratio for the end date of the IndexPeriod.

\[I(m) = \frac{I_{val}(m)}{I_{base}}\]
Parameters:

curve (IndexCurve) – The index curve from which index values are forecast.

Return type:

float, Dual, Dual2

npv(curve=NoInput.blank, disc_curve=NoInput.blank, fx=NoInput.blank, base=NoInput.blank, local=False)#

Return the cashflows of the IndexPeriod. See BasePeriod.npv()