FinancePy

FinancePy API Reference

float float cross ccy swap

financepy.products.rates.swaps.float_float_cross_ccy_swap

Class

FloatFloatCrossCurrencySwap

FloatFloatCrossCurrencySwap( effective_dt: Date, term_dt_or_tenor: Date | str, float_pay_freq_type: FrequencyTypes = <FrequencyTypes.QUARTERLY: 4>, float_pay_dc_type: DayCountTypes = <DayCountTypes.THIRTY_E_360: 2>, float_rec_freq_type: FrequencyTypes = <FrequencyTypes.QUARTERLY: 4>, float_rec_dc_type: DayCountTypes = <DayCountTypes.THIRTY_E_360: 2>, basis_swap_spread: float = 0.0, notional: float = 1000000, cal_type: CalendarTypes | list | tuple = <CalendarTypes.WEEKEND: 2>, bd_type: BusDayAdjustTypes = <BusDayAdjustTypes.FOLLOWING: 2>, dg_type: DateGenRuleTypes = <DateGenRuleTypes.BACKWARD: 2>, )
Class for managing an interest rate basis swap contract. This is a contract in which a floating leg with one LIBOR tenor is exchanged for a floating leg payment in a different LIBOR tenor. There is no exchange of par. The contract is entered into at zero initial cost. The contract lasts from a start date to a specified maturity date. The value of the contract is the NPV of the two cpn streams. Discounting is done on a supplied discount curve which is separate from the discount from which the implied index rates are extracted.

Methods

value

value( self, value_dt, discount_curve, pay_index_curve, rec_index_curve, pay_first_fixing_rate = None, rec_first_fixing_rate = None, principal = 0.0, )
Value the LIBOR basis swap on a value date given a single Ibor discount curve and each of the index discount for the two floating legs of the swap.

float_leg_value

float_leg_value( self, value_dt, discount_curve, index_curve, first_fixing_rate = None, principal = 0.0, )
Value the floating leg with payments from an index curve and discounting based on a supplied discount curve. The valuation date can be the today date. In this case the price of the floating leg will not be par (assuming we added on a principal repayment). This is only the case if we set the valuation date to be the swap's actual settlement date.

print_float_leg_pv

print_float_leg_pv( self, )
Prints the floating leg dates, accrual factors, discount factors, forward libor rates, implied cash amounts, their present value and their cumulative PV using the last valuation performed.
Generated automatically from the FinancePy source code. Do not edit this file manually.