"src/vscode:/vscode.git/clone" did not exist on "7f0d5358db824a6d1b0f41621952195e30082035"
Unverified Commit 8967debe authored by James Lamb's avatar James Lamb Committed by GitHub
Browse files

[R-package] remove unused internal variables (#5991)

parent 9a84b61d
......@@ -494,11 +494,10 @@ Dataset <- R6::R6Class(
if (info_len > 0L) {
# Get back fields
ret <- NULL
ret <- if (field_name == "group") {
integer(info_len)
if (field_name == "group") {
ret <- integer(info_len)
} else {
numeric(info_len)
ret <- numeric(info_len)
}
.Call(
......
......@@ -98,8 +98,6 @@ Predictor <- R6::R6Class(
start_iteration <- 0L
}
num_row <- 0L
# Check if data is a file name and not a matrix
if (identical(class(data), "character") && length(data) == 1L) {
......
......@@ -116,10 +116,6 @@ lgb.convert_with_rules <- function(data, rules = NULL) {
column_classes <- .get_column_classes(df = data)
is_char <- which(column_classes == "character")
is_factor <- which(column_classes == "factor")
is_logical <- which(column_classes == "logical")
is_data_table <- data.table::is.data.table(x = data)
is_data_frame <- is.data.frame(data)
......
......@@ -225,8 +225,6 @@ lgb.cv <- function(params = list()
stop(sQuote("folds"), " must be a list with 2 or more elements that are vectors of indices for each CV-fold")
}
nfold <- length(folds)
} else {
if (nfold <= 1L) {
......
......@@ -1341,7 +1341,7 @@ test_that("Booster's print, show, and summary work correctly", {
.has_expected_content_for_fitted_model(log_txt)
# summary()
log_text <- capture.output({
log_txt <- capture.output({
ret <- summary(model)
})
.have_same_handle(ret, model)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment