Skip to content

Commit 9715661

Browse files
authored
[R] Add 'label' to list of removals for xgb.cv (dmlc#11231)
1 parent 526e9cb commit 9715661

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

R-package/R/utils.R

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -557,6 +557,8 @@ deprecated_train_params <- list(
557557
),
558558
removed = character()
559559
)
560+
deprecated_cv_params <- deprecated_train_params
561+
deprecated_cv_params$removed <- 'label'
560562
deprecated_xgboost_params <- list(
561563
renamed = list(
562564
'data' = 'x',

R-package/R/xgb.cv.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ xgb.cv <- function(params = xgb.params(), data, nrounds, nfold,
110110
objective = NULL, custom_metric = NULL, stratified = "auto",
111111
folds = NULL, train_folds = NULL, verbose = TRUE, print_every_n = 1L,
112112
early_stopping_rounds = NULL, maximize = NULL, callbacks = list(), ...) {
113-
check.deprecation(deprecated_train_params, match.call(), ...)
113+
check.deprecation(deprecated_cv_params, match.call(), ...)
114114

115115
stopifnot(inherits(data, "xgb.DMatrix"))
116116
if (inherits(data, "xgb.DMatrix") && .Call(XGCheckNullPtr_R, data)) {

0 commit comments

Comments
 (0)