diff options
Diffstat (limited to 'python')
| -rw-r--r-- | python/analytics/index_data.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/python/analytics/index_data.py b/python/analytics/index_data.py index 18aeaaba..06c5cd00 100644 --- a/python/analytics/index_data.py +++ b/python/analytics/index_data.py @@ -152,6 +152,8 @@ def get_singlenames_quotes(indexname, date): def build_curve(r, tenors, currency="USD"): + if r['date'] is None: + raise ValueError(f"Curve for {r['cds_ticker']} is missing") spread_curve = 1e-4 * np.array(r['spread_curve'], dtype='float') upfront_curve = 1e-2 * np.array(r['upfront_curve'], dtype='float') recovery_curve = np.array(r['recovery_curve'], dtype='float') |
