Great tool - it's very cool stuff that you've done here. I was able to get it up and running and connected to our CDM instance (although I had to hardcode credentials into the app.R file), but I'm getting an odd error every time I try to load a patient's data. On line 600 of the PatientExploreR-OMOP_functions.R file, you use rbind() to append "master_report" with the summary reports with the rest of the domains. However, I'm getting a crash here with the message "Error in rbindlist: Class attribute on column 2 of item 3 does not match with column 2 of item 1." I'm assuming here that "item 3" is "conditions" and "item 1" is "master_report," and column 2 is obviously the "Date_end" column. But I'm not sure why this error is throwing, as they're both of the same class. I've tried adding a line at 556 forcing as.Date for condition_end_date:
Hi Ben,
Great tool - it's very cool stuff that you've done here. I was able to get it up and running and connected to our CDM instance (although I had to hardcode credentials into the app.R file), but I'm getting an odd error every time I try to load a patient's data. On line 600 of the PatientExploreR-OMOP_functions.R file, you use rbind() to append "master_report" with the summary reports with the rest of the domains. However, I'm getting a crash here with the message "Error in rbindlist: Class attribute on column 2 of item 3 does not match with column 2 of item 1." I'm assuming here that "item 3" is "conditions" and "item 1" is "master_report," and column 2 is obviously the "Date_end" column. But I'm not sure why this error is throwing, as they're both of the same class. I've tried adding a line at 556 forcing as.Date for condition_end_date:
conditions=conditions_original[,c("condition_start_date","condition_end_date","condition_concept_name","condition_source_value")] conditions$Type = "Condition" conditions=conditions[!duplicated(conditions),] conditions=conditions[!is.na(conditions$condition_start_date),] conditions=conditions[!is.na(conditions$condition_concept_name),] conditions$condition_end_date = as.Date(as.character(conditions$condition_end_date)) conditions=conditions[,c("condition_start_date","condition_end_date","Type","condition_concept_name","condition_source_value")] colnames(conditions)=c("Date","Date_end","Type","Event","Value")
but that didn't seem to solve the error. Any thoughts on how I might be able to resolve this?