diff options
| -rw-r--r-- | R/intex_deal_functions.R | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/R/intex_deal_functions.R b/R/intex_deal_functions.R index d24dd007..6fbad96b 100644 --- a/R/intex_deal_functions.R +++ b/R/intex_deal_functions.R @@ -189,7 +189,7 @@ buildSC.matured <- function(SC, line.item, reinvdate, dealmaturity, global.param buildSC <- function(line.item, reinvdate, dealmaturity, global.params, startdate){
if(!is.na(line.item$iscdo) && line.item$iscdo && is.na(line.item$price)){
##we have prices for some cdos e.g. 210795PS3
- if(line.item$orig_moody == "NA" || length(line.item$orig_moody)==0){
+ if(is.na(line.item$orig) || line.item$orig_moody == "NA" || length(line.item$orig_moody)==0){
line.item$orig_moody <- "NR"
}
line.item$price <- as.numeric(global.params$cdoprices[gsub("\\d", "", line.item$orig_moody)])
|
