| plot.rfmstate_importance | R Documentation |
Visualizes per-transition feature importance as a grouped barplot or heatmap.
## S3 method for class 'rfmstate_importance'
plot(
x,
type = c("barplot", "heatmap"),
col = NULL,
main = NULL,
xlab = NULL,
ylab = NULL,
...
)
x |
An |
type |
Character, one of |
col |
Bar colors or heatmap gradient-anchor colors. |
main |
Title. |
xlab, ylab |
Axis labels. |
... |
Additional graphical arguments. For a heatmap they are passed to
|
The input x object, returned invisibly. Called for its
side effect of producing a plot.
Values are transition-specific ranger importance scores. Negative values may arise from Monte Carlo noise, sparse events, correlated predictors, or irrelevant variables and are not protective or causal effects. Scales may differ across transitions.
imp <- structure(list(
importance_matrix = matrix(
c(0.2, -0.1), nrow = 2,
dimnames = list(c("x", "z"), "A->B")
)
), class = "rfmstate_importance")
plot(imp, xlab = "OOB loss increase", ylab = "Predictor")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.