aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--python/analytics/basket_index.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/python/analytics/basket_index.py b/python/analytics/basket_index.py
index f495b3bc..261197cc 100644
--- a/python/analytics/basket_index.py
+++ b/python/analytics/basket_index.py
@@ -6,6 +6,7 @@ import numpy as np
import pandas as pd
import datetime
from scipy.optimize import brentq
+from pandas.tseries.offsets import BDay
class BasketIndex(CreditIndex):
index_type: str
@@ -16,7 +17,7 @@ class BasketIndex(CreditIndex):
tweaks: List[float]
def __init__(self, index_type: str, series: int, tenors: List[str], *args,
- trade_date: pd.Timestamp=pd.Timestamp.today().normalize() - pd.Timedelta(days=1)):
+ trade_date: pd.Timestamp=pd.Timestamp.today().normalize() - BDay()):
self.index_type = index_type
self.series = series
if index_type == 'IG' or index_type == 'EU':