File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -242,7 +242,7 @@ DoubleMLIRM = R6Class("DoubleMLIRM",
242242 fold_specific_params = private $ fold_specific_params )
243243
244244 g1_hat = NULL
245- if ((is.character(self $ score ) && self $ score == " ATE" ) | is.function(self $ score )) {
245+ if ((is.character(self $ score ) && self $ score == " ATE" ) || is.function(self $ score )) {
246246 g1_hat = dml_cv_predict(self $ learner $ ml_g ,
247247 c(self $ data $ x_cols , self $ data $ other_treat_cols ),
248248 self $ data $ y_col ,
@@ -341,7 +341,7 @@ DoubleMLIRM = R6Class("DoubleMLIRM",
341341 tune_settings $ measure $ ml_g ,
342342 private $ learner_class $ ml_g )
343343
344- if (self $ score == " ATE" | is.function(self $ score )) {
344+ if ((is.character( self $ score ) && self $ score == " ATE" ) | | is.function(self $ score )) {
345345 tuning_result_g1 = dml_tune(self $ learner $ ml_g ,
346346 c(self $ data $ x_cols , self $ data $ other_treat_cols ),
347347 self $ data $ y_col ,
You can’t perform that action at this time.
0 commit comments