Extended compatibility with xgboost, now requiring xgboost (>= 3.0.0) in Suggests:
Plot colors are now configurable via options() and documented in ?glex_options:
glex.palette (diverging palette for continuous interaction effects; NULL for the
default shap-style gradient, or the name of a scico palette),
glex.palette_discrete (palette for categorical predictors: a color vector,
"okabe-ito", a scico palette name, or a brewer palette name),
glex.colors_sign (negative/positive colors in glex_explain() and gradient endpoints), and
glex.color_line (main effect line/column color).
Default colors updated to follow the blue/red convention of the Python shap/shapiq
packages: continuous interaction effects use a #008BFB → white → #FF0051 gradient
(previously the cyclic scico palette "vikO"), and glex_explain() uses the same
blue/red for negative/positive contributions.
Quality to Gain, matching xgboost commit 73713de ([R] rename Quality -> Gain (#9938), in upstream v2.1.0)base_score extraction to replace hardcoded 0.5 intercept (modern xgboost auto-estimates base_score)glex() to accept data frames as inputprobFuntion parameter to glex() in favor of weighting_method.glex()max_interaction (#24)probFunction in glex.plot_*_effect[s] functions for continuous predictors, defaulting to showing a rug on the bottom side (rug_side = "b").glex() (PR#17).probFunction to glex() which specifies the probability function for weighting/marginalization of the leaves (PR#17).glex() now uses the empirical marginal probabilities to perform the weighting. Previously, the weighting of the leaves was done based on a path-dependent method.theme_glex() as a default theme to all plots.ggplot2::theme_minimal()] aside from increased base font size
and convenience flags to toggle vertical and horizontal grid lines.subset_components() and subset_component_names() to make it easier to extract only components belonging to a given main term.Bikeshare data from ISLR2 to streamlined examples.plot_pdp(), a version of plot_main_effect() with the intercept added.max_interaction in glex.xgb.Booster to max_depth parameter of xgboost model.
If max_depth is not set during model fit, the default value of 6 is assumed.
This prevents glex from returning spurious higher-order interactions containing values numerically close to 0.glex_explain to a waterfall plot showing the SHAP decomposition for given predictors.autoplot.glex_vi gains a max_interaction argument in line with glex_explain, and now similarly aggregates terms that either fall below threshold or exceed max_interaction.glex.print for a more compact output in case of large numbers of terms.ggplot2::autoplot S3 method for glex objects.pkgdown siteglex_vi() to compute variable importance scores including interaction terms, including a
corresponding ggplot2::autoplot method.glex_explain() to plot prediction components of a single observation.glex() to an S3 generic function with methods for xgboost and randomPlantedForest models.xgboost method that could lead to wrongly computed shap values in certain cases.NEWS.md file to track changes to the package.