* using log directory 'd:/Rcompile/CRANpkg/local/4.4/SHAPforxgboost.Rcheck' * using R version 4.4.3 (2025-02-28 ucrt) * using platform: x86_64-w64-mingw32 * R was compiled by gcc.exe (GCC) 13.3.0 GNU Fortran (GCC) 13.3.0 * running under: Windows Server 2022 x64 (build 20348) * using session charset: UTF-8 * checking for file 'SHAPforxgboost/DESCRIPTION' ... OK * this is package 'SHAPforxgboost' version '0.1.3' * package encoding: UTF-8 * checking package namespace information ... OK * checking package dependencies ... OK * checking if this is a source package ... OK * checking if there is a namespace ... OK * checking for hidden files and directories ... OK * checking for portable file names ... OK * checking whether package 'SHAPforxgboost' can be installed ... OK * checking installed package size ... OK * checking package directory ... OK * checking 'build' directory ... OK * checking DESCRIPTION meta-information ... OK * checking top-level files ... OK * checking for left-over files ... OK * checking index information ... OK * checking package subdirectories ... OK * checking code files for non-ASCII characters ... OK * checking R files for syntax errors ... OK * checking whether the package can be loaded ... [5s] OK * checking whether the package can be loaded with stated dependencies ... [4s] OK * checking whether the package can be unloaded cleanly ... [4s] OK * checking whether the namespace can be loaded with stated dependencies ... [4s] OK * checking whether the namespace can be unloaded cleanly ... [4s] OK * checking loading without being on the library search path ... [4s] OK * checking use of S3 registration ... OK * checking dependencies in R code ... OK * checking S3 generic/method consistency ... OK * checking replacement functions ... OK * checking foreign function calls ... OK * checking R code for possible problems ... [11s] OK * checking Rd files ... [1s] OK * checking Rd metadata ... OK * checking Rd cross-references ... OK * checking for missing documentation entries ... OK * checking for code/documentation mismatches ... OK * checking Rd \usage sections ... OK * checking Rd contents ... OK * checking for unstated dependencies in examples ... OK * checking contents of 'data' directory ... OK * checking data for non-ASCII characters ... [1s] OK * checking LazyData ... OK * checking data for ASCII and uncompressed saves ... OK * checking installed files from 'inst/doc' ... OK * checking files in 'vignettes' ... OK * checking examples ... [23s] ERROR Running examples in 'SHAPforxgboost-Ex.R' failed The error most likely occurred in: > ### Name: shap.plot.summary > ### Title: SHAP summary plot core function using the long format SHAP > ### values > ### Aliases: shap.plot.summary > > ### ** Examples > > data("iris") > X1 = as.matrix(iris[,-5]) > mod1 = xgboost::xgboost( + data = X1, label = iris$Species, gamma = 0, eta = 1, + lambda = 0, nrounds = 1, verbose = FALSE, nthread = 1) Warning in throw_err_or_depr_msg("Passed unrecognized parameters: ", paste(head(names_unrecognized), : Passed unrecognized parameters: verbose. This warning will become an error in a future version. Warning in throw_err_or_depr_msg("Parameter '", match_old, "' has been renamed to '", : Parameter 'data' has been renamed to 'x'. This warning will become an error in a future version. Warning in throw_err_or_depr_msg("Parameter '", match_old, "' has been renamed to '", : Parameter 'label' has been renamed to 'y'. This warning will become an error in a future version. Warning in throw_err_or_depr_msg("Parameter '", match_old, "' has been renamed to '", : Parameter 'gamma' has been renamed to 'min_split_loss'. This warning will become an error in a future version. Warning in throw_err_or_depr_msg("Parameter '", match_old, "' has been renamed to '", : Parameter 'eta' has been renamed to 'learning_rate'. This warning will become an error in a future version. Warning in throw_err_or_depr_msg("Parameter '", match_old, "' has been renamed to '", : Parameter 'lambda' has been renamed to 'reg_lambda'. This warning will become an error in a future version. > > # shap.values(model, X_dataset) returns the SHAP > # data matrix and ranked features by mean|SHAP| > shap_values <- shap.values(xgb_model = mod1, X_train = X1) Warning in `[.data.table`(shap_contrib, , `:=`(BIAS, NULL)) : Tried to assign NULL to column 'BIAS', but this column does not exist to remove > shap_values$mean_shap_score setosa versicolor virginica 0.3360065 0.3326459 0.3313476 > shap_values_iris <- shap_values$shap_score > > # shap.prep() returns the long-format SHAP data from either model or > shap_long_iris <- shap.prep(xgb_model = mod1, X_train = X1) Warning in `[.data.table`(shap_contrib, , `:=`(BIAS, NULL)) : Tried to assign NULL to column 'BIAS', but this column does not exist to remove Error in `[.data.table`(setDT(shap$shap_score), , names(shap$mean_shap_score)[1:top_n], : column not found: [NA] Calls: shap.prep ... [ -> [.data.table -> stopf -> raise_condition -> signal Execution halted * checking for unstated dependencies in vignettes ... OK * checking package vignettes ... OK * checking re-building of vignette outputs ... [6s] ERROR Error(s) in re-building vignettes: --- re-building 'basic_workflow.Rmd' using rmarkdown Quitting from basic_workflow.Rmd:62-87 [unnamed-chunk-3] ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Error in `[.data.table`: ! column not found: [(Intercept)] --- Backtrace: ▆ 1. └─SHAPforxgboost::shap.prep(fit, X_train = X) 2. ├─...[] 3. └─data.table:::`[.data.table`(...) 4. └─data.table:::stopf(...) 5. └─data.table:::raise_condition(...) ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Error: processing vignette 'basic_workflow.Rmd' failed with diagnostics: column not found: [(Intercept)] --- failed re-building 'basic_workflow.Rmd' SUMMARY: processing the following file failed: 'basic_workflow.Rmd' Error: Vignette re-building failed. Execution halted * checking PDF version of manual ... [18s] OK * checking HTML version of manual ... [4s] OK * DONE Status: 2 ERRORs