aboutsummaryrefslogtreecommitdiffstats
path: root/python/analytics/basket_index.py
diff options
context:
space:
mode:
Diffstat (limited to 'python/analytics/basket_index.py')
-rw-r--r--python/analytics/basket_index.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/python/analytics/basket_index.py b/python/analytics/basket_index.py
index 4c08c157..612fb733 100644
--- a/python/analytics/basket_index.py
+++ b/python/analytics/basket_index.py
@@ -121,8 +121,11 @@ class BasketIndex(CreditIndex):
def _get_quotes(self, *args):
""" allow to tweak based on manually inputed quotes"""
- return {m: self._snacpv(s*1e-4, self.coupon(m), self.recovery, m)
- for m, s in zip(self.maturities, args[0])}
+ if self.index_type == "HY":
+ return {m: (100-p)/100 for m, p in zip(self.maturities, args[0])}
+ else:
+ return {m: self._snacpv(s*1e-4, self.coupon(m), self.recovery, m)
+ for m, s in zip(self.maturities, args[0])}
value_date = property(CreditIndex.value_date.__get__)