I'm trying to explore the use of a GBM with h2o for a classification issue to replace a logistic regression (GLM). The non-linearity and interactions in my data make me think a GBM is more suitable.
I've run a baseline GBM (see below) and compared the AUC against the AUC of the logistic regression. THe GBM performs much better.
In a classic linear logistic regression, one would be able to see the direction and effect of each of the predictors (x) on the outcome variable (y).
Now, I would like to evaluate the variable importance of the estimate GBM in the same way.
How does one obtain the variable importance for each of the (two) classes?
I know that the variable importance is not the same as the estimated coefficient in logistic regression, but it would help me to understand which predictor impacts what class.
Others have asked similar questions, but the answers provided won't work for the H2O object.
Any help is much appreciated.
example.gbm <- h2o.gbm(
x = c("list of predictors"),
y = "binary response variable",
training_frame = data,
max_runtime_secs = 1800,
stopping_metric = "AUC")