
Calculate SHAP values for all ML models
calculate_all_shap.RdThis function iterates over a list of machine learning models, calculates SHAP values for each model using the
calculate_variable_importance_batch function, and compiles the results into a list. It also ensures that
the necessary package for explaining tidymodels is available and handles the renaming of model labels for better
readability in the output.
Usage
calculate_all_shap(
ml_models_to_run,
results_models,
expression_data,
target_var,
directory_to_save = NULL
)