TotalReturnSwap

TotalReturnSwap#

class sigtech.framework.instruments.trs_otc.TotalReturnSwap

Baseclasses: TradableInstrument

Class implementing a total return swap on a given underlyer. The swap is assumed to be cancellable at any moment in time, and as such its value on any given day is the change in the asset value minus the accrued financing. For the total return history, all the cashflows that happened to date are accumulated (or expected to happen in any case) on top of this.

Currently, no additional interest/discounting is applied to the cashflows once they happen.

The swap is assumed to be settling on the same day as would settle the underlying instrument.

The underlyings currently supported are bond, single stock, and total return index.

Example of object creation:

sig.TotalReturnSwap(
    currency='USD',
    trade_date=dtm.date(2017, 2, 6),
    maturity=dtm.date(2017, 3, 13),
    instrument_name='SPXT Index',
    financing_ticker=('FEDL01 INDEX', '1M'),
    financing_spread=200
)

Here SPXT index return is exchanged for monthly reset FedFunds rate plus 200bp.

financing_spread: Optional[float]
financing_ticker: Optional[list[str]]
instrument_name: str
maturity: date
property settlement_type

Type of settlement, e.g. 'Cash' or 'Physical'.

property size_type

Type of trade size for the instrument.

strike: Optional[float]
trade_date: date
property valuation_time

Valuation time for the instrument.

calendar_schedule()

Calendar schedule for this instrument.

cashflows()

Return the cash flows of the instrument.

static fair_strike(instrument_name, dt, mode='mid', include_trading_costs=True, transaction_type=None)

Fair strike value.

Parameters:
  • instrument_name – Instrument name.

  • dt – Quote date.

  • mode – Mode (optional, default is 'mid').

  • include_trading_costs – True if trading costs should be included.

  • transaction_type – String identifier to indicate type of transaction, e.g. 'outright', 'roll'.

Returns:

Fair strike.

unit_strike()

Strike used to calculate the reference underlyers units in the model output.