summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGuillaume Horel <guillaume.horel@gmail.com>2020-11-13 15:57:19 -0500
committerGuillaume Horel <guillaume.horel@gmail.com>2020-11-13 16:14:24 -0500
commit3be205c245acbeaf1dd8866b59a57638f78bd3a2 (patch)
treeae1aacde647fe933b6c6c2910e499d28fa0829c6
parent20b378876a27e833160d6d039f46c0e0723a4a48 (diff)
downloadpyisda-3be205c245acbeaf1dd8866b59a57638f78bd3a2.tar.gz
use full ticker
-rw-r--r--c_layer/survival_curve.hpp2
-rw-r--r--pyisda/credit_index.pyx2
2 files changed, 2 insertions, 2 deletions
diff --git a/c_layer/survival_curve.hpp b/c_layer/survival_curve.hpp
index 7032687..ce71cc1 100644
--- a/c_layer/survival_curve.hpp
+++ b/c_layer/survival_curve.hpp
@@ -20,7 +20,7 @@ struct CurveName {
strcpy((char*)buf, ticker.c_str());
};
- std::string full_ticker() {
+ std::string full_ticker() const {
std::string r = ticker;
return r.append("_").append(str_seniority()).
append("_").append(str_doc_clause());
diff --git a/pyisda/credit_index.pyx b/pyisda/credit_index.pyx
index 32e6c56..9a70125 100644
--- a/pyisda/credit_index.pyx
+++ b/pyisda/credit_index.pyx
@@ -347,7 +347,7 @@ cdef class CreditIndex(CurveList):
for p in self.names:
sc = self._curves[p.second].get()
- tickers.append(p.first.ticker)
+ tickers.append(p.first.full_ticker())
# TODO: pick the actual recovery on the curve
# this only works for flat recovery curve
recovery_rate = self.recovery_rates[p.second].get()[0]