5. CDS Hedging¶

Investigate the use of Credit Default Swaps (CDS) to hedge Perishing Sqaure's portfolio against market risk.

Review¶

For CDS contracts, the buyer and seller of default protection would initially exchange an “upfront” amount, after which the buyer made quarterly fixed coupon payments to the seller over the life of the contract. In return, for every notional dollar of protection, the seller of CDS would make a payment to the buyer if the bond experienced a so-called “credit event,” such as default or debt restructuring.

The CDS contracts bought by Perishing Square were written on individual bonds were known as single-name CDSs, but there were also contracts known as index CDS's that were written on baskets or portfolios of bonds. The two most common index CDS families were the CDX and iTraxx indices. The CDX indices tracked American Companies, while the iTraxx indices tracked European companies.

In addition, index CDS are centrally cleared which means that a clearing house acted as a counterparty to both sides of the transaction. When purchasing CDS protection on centrally cleared contracts, both parties were required to post initial margin based on the notional value of the contract and the risk of the underlying. This was in addition to any upfront payments made between the parties. Pershing Square estimated that their initial margins on the IG, iTraxx, and HY indices would be 0.8%, 0.9%, and 3.2% of notional, respectively.

In order to hedge Perishing Portfolio from market risk, the entire portfolio value at 2020-02-21 was hedged. This can be found

Information Sourced:¶

  • Since there was limited free information about CDS spreads, an article, written by "The Short Bear" was found. The link to the site: https://theshortbear.substack.com/p/bill-ackmans-2650000000-trade.
  • Calculations and spread information was sourced by the author of the document. (Found in excel file used)

Assumptions and Limitations¶

  • With the excel file, it was decided that only one type of Credit Default Swaps (CDS) would be used to hedge its market risk/exposure.
  • To see the effectiveness of hedging, we can invest in CDS that has same notional amount of Perishing's portfolio at 02-21.
  • We also incoporated an upfront payment that needed to be paid from the buyer to the seller. That was calculated in this notebook.
  • We can take a look at the generated profits from each single index and how they hedge against the lose of their portfolio with the use of the graph generated in this notebook.
In [ ]:
import yfinance as yf
import pandas as pd
import matplotlib.pyplot as plt
import matplotlib.dates as mdates
import numpy as np
from datetime import datetime

import warnings
warnings.filterwarnings("ignore")

Working¶

In [ ]:
QUARTER = 0.25
#THIS STUFF MAY NOT BE NEEDED
NOTIONAL_CONTRACT = 100
# MATURITY = 5
EXPECTED_HOLDING_PERIOD = 60 #Expected to hold CDS for 60 days. 

# #Current Data as of 02-21-2020
# RISKLESS_RATE_02_21 = 0.0130 #(Same between both indexes)

BREAKEVEN_CDXHY_SPREAD_02_21 = 0.0295
BREAKEVEN_CDXIG_SPREAD_02_21 = 0.0046

CDX_HY_UPFRONT_PAYMENT_PERCENTAGE_02_21 = 8.97/NOTIONAL_CONTRACT   #Per $100 of investment size, firm has to pay $8.97 
CDX_IG_UPFRONT_PAYMENT_PERCENTAGE__02_21 = 2.55/NOTIONAL_CONTRACT    

RECOVERY_RATE_CDXHY = 0.3 
RECOVERY_RATE_CDXIG = 0.4
FIXED_CDS_PREMIUM_CDXIG = 0.01
FIXED_CDS_PREMIUM_CDXHY = 0.05


# LIQUIDATION_DATE = '4-21-2020'
# RISKLESS_RATE_04_21 = 0.0034
# BREAKEVEN_CDXHY_SPREAD_04_21 = 0.06
# CDX_HY_UPFRONT_PAYMENT_04_21 = 4.03

# BREAKEVEN_CDXIG_SPREAD_04_21 = 0.016
# CDX_IG_UPFRONT_PAYMENT_02_21 = 2.79

# #Expected Costs and Payoffs
# FIXED_COUPON_PAID_CDXHY = 0.83
# PAYOFF_CHANGE_IN_UPFRONT_CDXHY = 13
# MULTIPLE_ON_PREMIUMS_CDXHY = 15.6

# FIXED_COUPON_PAID_CDXIG = 0.17
# PAYOFF_CHANGE_IN_UPFRONT_CDXIG = 5.33
# MULTIPLE_ON_PREMIUMS_CDXIG = 32.0

VALUE_PORTFOLIO_02_21 = 7697406096.30

DOUBLE_VALUE_PORTFOLIO_02_21 = 15394812192.6

#Calculate upfront payment for CDS 
CDX_HY_UPFRONT_PAYMENT = CDX_HY_UPFRONT_PAYMENT_PERCENTAGE_02_21 * VALUE_PORTFOLIO_02_21
print("CDX HY Upfront Cost:",  CDX_HY_UPFRONT_PAYMENT)

CDX_IG_UPFRONT_PAYMENT = CDX_IG_UPFRONT_PAYMENT_PERCENTAGE__02_21 * VALUE_PORTFOLIO_02_21
print("CDX IG Upfront Cost:",  CDX_IG_UPFRONT_PAYMENT)

CDX_HY_DOUBLE_UPFRONT_PAYMENT = DOUBLE_VALUE_PORTFOLIO_02_21 * CDX_HY_UPFRONT_PAYMENT_PERCENTAGE_02_21
print ("CDX_HY_Upfront Cost (Double):", CDX_HY_DOUBLE_UPFRONT_PAYMENT)

CDX_IG_DOUBLE_UPFRONT_PAYMENT = DOUBLE_VALUE_PORTFOLIO_02_21 * CDX_IG_UPFRONT_PAYMENT_PERCENTAGE__02_21
print ("CDX_IG_Upfront Cost (Double):", CDX_IG_DOUBLE_UPFRONT_PAYMENT)

#Rest can be found in an excel file
CDX HY Upfront Cost: 690457326.8381101
CDX IG Upfront Cost: 196283855.45565
CDX_HY_Upfront Cost (Double): 1380914653.6762202
CDX_IG_Upfront Cost (Double): 392567710.9113

Payoffs from Hedging Perishing Portfolio Value at Feb-21 2020

In [ ]:
file_path = 'Bill Ackman $2.65b trade.xlsx'
sheet_name = 'Hedging'

#Just for formatting purposes
def format_dollars(val):
    if pd.notna(val):  
        return "${:,.2f}".format(val)
    else:
        return val  

df = pd.read_excel(file_path, sheet_name=sheet_name)
df['Payoffs'] = df['Payoffs'].apply('${:,.2f}'.format)
df['Spreads Before'] = (df['Spreads Before'] * 100).apply('{:.2f}%'.format)
df['Spreads After'] = (df['Spreads After'] * 100).apply('{:.2f}%'.format)
df['CDS Spread'] = (df['CDS Spread'] * 100).apply('{:.2f}%'.format)
df['Quarterly Premiums'] = df['Quarterly Premiums'].apply(format_dollars)
df['Upfront Payment $100 Notional value'] = df['Upfront Payment $100 Notional value'].apply(format_dollars)
df['Upfront Payment'] = df['Upfront Payment'].apply(format_dollars)

df.head()
Out[ ]:
CDS Payoffs Spreads Before Spreads After CDS Spread Quarterly Premiums Upfront Payment $100 Notional value Upfront Payment
0 CDX IG $263,337,103.64 0.59% 1.30% 0.71% $22,707,347.98 $2.55 $196,283,855.46
1 CDX HY $1,235,088,105.78 3.46% 6.79% 3.33% $133,165,125.47 $8.97 $690,457,326.80
2 ITRAXX Main $248,501,210.47 0.60% 1.27% 0.67% $23,092,218.29 NaN NaN

Payoffs Hedging With a Different Value

  • The updated value is twice the value of the Perishing Portfolio as of February 21st.
  • Using same excel spreadsheet, these are the new values:
In [ ]:
file_path = 'Bill Ackman $2.65b trade.xlsx'
sheet_name = 'Hedging V2'


df2 = pd.read_excel(file_path, sheet_name=sheet_name)
df2['Payoffs'] = df2['Payoffs'].apply('${:,.2f}'.format)
df2['Spreads Before'] = (df2['Spreads Before'] * 100).apply('{:.2f}%'.format)
df2['Spreads After'] = (df2['Spreads After'] * 100).apply('{:.2f}%'.format)
df2['CDS Spread'] = (df2['CDS Spread'] * 100).apply('{:.2f}%'.format)
df2['Quarterly Premiums'] = df2['Quarterly Premiums'].apply(format_dollars)
df2['Upfront Payment $100 Notional value'] = df2['Upfront Payment $100 Notional value'].apply(format_dollars)
df2['Upfront Payment'] = df2['Upfront Payment'].apply(format_dollars)

df2.head()
Out[ ]:
CDS Payoffs Spreads Before Spreads After CDS Spread Quarterly Premiums Upfront Payment $100 Notional value Upfront Payment
0 CDX IG $526,674,207.27 0.59% 1.30% 0.71% $50,033,139.63 $2.55 $392,567,710.90
1 CDX HY $2,470,176,211.57 3.46% 6.79% 3.33% $133,165,125.47 $8.97 $1,380,914,654.00
2 ITRAXX Main $497,002,420.95 0.60% 1.27% 0.67% $23,092,218.29 NaN NaN