RollingCreditIndexStrategy

RollingCreditIndexStrategy#

class sigtech.framework.strategies.rolling_credit_index_strategy.RollingCreditIndexStrategy

Baseclasses: RollingStrategyBase

Strategy creating exposure to a credit index. The roll schedule is either defined by the custom_roll_dates list, or generated according to the reinvestment_mode and rolling_frequencies parameters. Since almost all of the liquidity sits in the on-the-run series, we must roll around the dates when a new series is issued. Additionally, it is possible to reinvest the coupons. Possible values for the reinvestment_mode are:

  • 'Coupon': reinvest coupon and default settlement payments on the roll dates.

  • 'Total': reinvest the whole value of the strategy on the roll dates.

  • 'None': keep a constant exposure in the index equal to the initial_cash of the strategy.

Keyword arguments:

  • index: Name of the credit index to trade, e.g. 'XOVER', 'CDX'.

  • tenor: Tenor of the credit index, e.g. '5Y'.

  • reinvestment_mode: Defines the new exposure to the index on roll dates.

  • rolling_frequencies: '3M' to reinvest around coupon dates, '6M' to reinvest only on new series issue dates.

  • roll_offset: Offset in business days from coupon or series issue dates, must be non-negative.

  • custom_roll_dates: If not None, defines the roll schedule manually.

Example object creation:

import datetime as dtm

s = sig.RollingCreditIndexStrategy(
    currency='USD',
    start_date=dtm.date(2010, 1, 4),
    end_date=dtm.date(2021, 11, 30),
    index='CDX',
    tenor='5Y'
)
currency: Optional[str]
custom_roll_dates: Optional[list[datetime.date]]
property holidays

List of known holiday calendars.

index: str
rebalance_frequency: Optional[Literal['3M', '6M']]
reinvestment_mode: Optional[Literal['Coupon', 'Total', 'None']]
roll_offset: Optional[Union[str, int]]
roll_offset_days: Optional[int]
rolling_frequencies: Optional[Literal['3M', '6M']]
property rolling_table

Builds the strategy’s rolling table.

Returns:

Built rolling table as a pandas DataFrame.

tenor: str
bd_schedule() StrategySchedule

Combined schedule of the group’s and TradingManager’s holidays.

generate_roll_dates(d: date)

Populates the roll dates from a given date until the end of the strategy.

Parameters:

d – Input date.

rolling_schedule()

Determine the dates to trade on.

schedule_information() StrategySchedule

Schedule using the group’s holidays.

strategy_initialization(dt)

Initial decision run on the start date of the strategy.

Parameters:

dt – Reference datetime.