Skip to content

Commit

Permalink
Fix argument "params" is missing, with no default when using custom (#…
Browse files Browse the repository at this point in the history
…1254)

objective funciton in reset_parameter()

Fixes error algb.params2str to lgb.params2str
  • Loading branch information
awalker89 authored and guolinke committed Feb 28, 2018
1 parent 5f2d561 commit 98c6efe
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions R-package/R/lgb.Booster.R
Expand Up @@ -167,7 +167,7 @@ Booster <- R6Class(

# Append parameters
params <- append(params, list(...))
params_str <- algb.params2str(params)
params_str <- lgb.params2str(params)

# Reset parameters
lgb.call("LGBM_BoosterResetParameter_R",
Expand Down Expand Up @@ -222,7 +222,7 @@ Booster <- R6Class(
stop("lgb.Booster.update: fobj should be a function")
}
if (!private$set_objective_to_none) {
self$reset_parameter(objective="none")
self$reset_parameter(params = list(objective = "none"))
private$set_objective_to_none = TRUE
}
# Perform objective calculation
Expand Down

0 comments on commit 98c6efe

Please sign in to comment.