Skip to content

Commit

Permalink
Fixes estimation bug when target has no comparator for CM
Browse files Browse the repository at this point in the history
  • Loading branch information
anthonysena committed Jul 30, 2024
1 parent a0ccde7 commit a7b6685
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion R/estimation-cohort-method-diagnostics.R
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@ estimationGetCmDiagnostics <- function(
{@use_analyses}?{and cma.analysis_id in (@analyses)}
;
"
print(comparatorIds)

result <- connectionHandler$queryDb(
sql = sql,
Expand All @@ -104,7 +105,7 @@ estimationGetCmDiagnostics <- function(
comparators = paste0(comparatorIds, collapse = ','),
outcomes = paste0(outcomeId, collapse = ','),

use_comparators = T,
use_comparators = ifelse(is.null(comparatorIds), F, T),
use_analyses = F
)

Expand Down

0 comments on commit a7b6685

Please sign in to comment.