You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I found that modelStudio would not allow a model_explainer object when model has only one variable.
There is the following example:
titanic_imputed_sub<- subset(titanic_imputed, select= c("survived", "class"))
model_titanic<- glm(survived~class, data=titanic_imputed_sub, family="binomial")
# create an explainer for the modelexplainer_titanic<- explain(model_titanic,
data=titanic_imputed_sub,
y=titanic_imputed$survived,
label="Titanic GLM")
# pick observationsnew_observations<-titanic_imputed[1:2,]
rownames(new_observations) <- c("Lucas","James")
# make a studio for the model
modelStudio(explainer_titanic,
new_observations, eda=FALSE,
N=200, B=5)
Calculating ...
Calculating ingredients::feature_importance
Elapsed time: 00:00:00 ETA: 0s Error in `[.default`(data, , , drop = FALSE) : 維度數目不正確
此外: Warning message:
In value[[3L]](cond) :
Error occurred in ingredients::feature_importance function: 長度為 0 的引數
Called from: NextMethod("[")
The text was updated successfully, but these errors were encountered:
Dear Maintainer
I found that modelStudio would not allow a model_explainer object when model has only one variable.
There is the following example:
The text was updated successfully, but these errors were encountered: