From 447cbcf8fca1601079604e015c68fb52171ae2ab Mon Sep 17 00:00:00 2001 From: Michael Mayer Date: Tue, 18 Jul 2023 19:17:06 +0200 Subject: [PATCH 1/2] package_version >= "4" instead of 4 --- NEWS.md | 4 ++++ R/shapviz.R | 2 +- cran-comments.md | 36 ++++++++++-------------------------- 3 files changed, 15 insertions(+), 27 deletions(-) diff --git a/NEWS.md b/NEWS.md index 901c6ca..0124b4d 100644 --- a/NEWS.md +++ b/NEWS.md @@ -4,6 +4,10 @@ - `dimnames.shapviz()` has received a replacement method. You can thus change the column names of SHAP matrix and feature data (as well as SHAP interactions) by `colnames(x) <- ...`, see https://github.com/ModelOriented/shapviz/issues/98 +## Maintenance + +- Fix for https://github.com/ModelOriented/shapviz/issues/100 (`package_version()` applied to numeric value will be deprecated in the future) + # shapviz 0.9.0 ## New features diff --git a/R/shapviz.R b/R/shapviz.R index e1f61a2..7b2d010 100644 --- a/R/shapviz.R +++ b/R/shapviz.R @@ -251,7 +251,7 @@ shapviz.lgb.Booster = function(object, X_pred, X = X_pred, ) # Switch for different versions of predict.lgb.Booster() - is_v4 <- utils::packageVersion("lightgbm") >= 4 + is_v4 <- utils::packageVersion("lightgbm") >= "4" has_type <- "type" %in% names(formals(utils::getS3method("predict", "lgb.Booster"))) if (is_v4 || has_type) { S <- stats::predict(object, newdata = X_pred, type = "contrib", ...) diff --git a/cran-comments.md b/cran-comments.md index c1cd7fe..7e6fffb 100644 --- a/cran-comments.md +++ b/cran-comments.md @@ -1,43 +1,27 @@ -# Re-resubmission - -Examples that take 0.09 seconds on my Windows laptop take 6 seconds on Linux. I don't know how to fix this, so I am resorting to dontruns around all examples involving XGBoost. - -# Re-resubmission - -Examples still taking too long on Linux. No idea how to fix this except using dontruns... - -# Resubmission - -Examples taking too long on Linux. - -- I have now reduced the number of examples. -- And the number of boosting rounds. - -# shapviz 0.9.0 +# shapviz 0.9.1 Hello CRAN team -- I have added a beautiful house price dataset with 14000 transactions from Miami in 2016. A friend of mine has created it (Prof. Steven Bourassa). -- There is a new plot `sv_dependence2D()` that is ideal for visualization of geographic components. -- Added new vignette on SHAP analyses for models with geographic components. +This is a small release fixing a future problem pointed out by Kurt Hornik about applying package_version() to numeric input. ## Checks look good ### check(manual = TRUE, cran = TRUE) -> checking HTML version of manual ... NOTE +- checking for future file timestamps ... NOTE + unable to verify current time + +- checking HTML version of manual ... NOTE Skipping checking HTML validation: no command 'tidy' found ### RHub -* checking package dependencies ... NOTE -Packages which this enhances but not available for checking: - 'fastshap', 'h2o', 'lightgbm' -* checking HTML version of manual ... NOTE -Skipping checking HTML validation: no command 'tidy' found -Skipping checking math rendering: package 'V8' unavailable +debian ok +Others: hanging ### Winbuilder() Status: OK +R Under development (unstable) (2023-07-17 r84702 ucrt) + From bd7cb1d7abe0ce1574681ff11a0e629c308c75cd Mon Sep 17 00:00:00 2001 From: Michael Mayer Date: Tue, 18 Jul 2023 21:23:07 +0200 Subject: [PATCH 2/2] Accepted by CRAN --- CRAN-SUBMISSION | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/CRAN-SUBMISSION b/CRAN-SUBMISSION index ab6e4fc..218dd8c 100644 --- a/CRAN-SUBMISSION +++ b/CRAN-SUBMISSION @@ -1,3 +1,3 @@ -Version: 0.9.0 -Date: 2023-06-09 14:22:29 UTC -SHA: 3f6bd1f781851c169a080adb317142b133f58147 +Version: 0.9.1 +Date: 2023-07-18 17:24:12 UTC +SHA: 447cbcf8fca1601079604e015c68fb52171ae2ab