quantlib.instruments.bonds.floatingratebond.FloatingRateBond¶
- class FloatingRateBond(Natural settlement_days, Real face_amount, Schedule schedule, IborIndex ibor_index, DayCounter accrual_day_counter, Natural fixing_days=Null[Natural](), vector[Real] gearings=[1.], vector[Spread] spreads=[0.], vector[Rate] caps=[], vector[Rate] floors=[], BusinessDayConvention payment_convention=Following, bool in_arrears=False, Real redemption=100.0, Date issue_date=Date(), Period ex_coupon_period=Period(), Calendar ex_coupon_calendar=Calendar(), BusinessDayConvention ex_coupon_convention=Unadjusted, bool ex_coupon_end_of_month=False)¶
Bases:
Bond
Floating rate bond
- __init__()¶
Floating rate bond
- Parameters:
settlement_days (int) – Number of days before bond settles
face_amount (float (C double in python)) – Amount of face value of bond
float_schedule (Schedule) – Schedule of payments for bond
ibor_index (IborIndex) – Ibor index
accrual_day_counter (DayCounter) – dayCounter for Bond
fixing_days (int) – Number of fixing days for bond
gearings (list [float]) – Gearings defaulted to [1.]
spreads (list [float]) – Spread on ibor index, default to [0.]
caps (list [float]) – Caps on the spread
floors (list[float]) – Floors on the spread
payment_convention (BusinessDayConvention) – The business day convention for the payment schedule
in_arrears (bool)
redemption (float) – Amount at redemption
issue_date (Date) – Date bond was issued
ex_coupon_period (Period)
ex_coupon_calendar (Calendar)
ex_coupon_convention (BusinessDayConvention)
ex_coupon_end_of_month (bool)
Methods
Floating rate bond
accrued_amount
(self, Date date=Date)Returns the bond accrued amount at the given date
bond_yield
(self, Real price, DayCounter dc, ...)Return the yield given a price and settlement date
notional
(self, Date date=Date)set_pricing_engine
(self, PricingEngine engine)Sets the pricing engine.
settlement_date
(self, Date from_date=Date)Returns the bond settlement date after the given date.
Attributes
calendar
cashflows
cash flow stream as a Leg
clean_price
Bond clean price.
dirty_price
Bond dirty price
is_expired
issue_date
Bond issue date
maturity_date
Bond maturity date
net_present_value
Instrument net present value.
npv
Shortcut to the net_present_value property.
settlement_days
start_date
Bond start date
valuation_date