Comments (8)
If anyone still had troubles with the first error (even after updating breakDown) - check if you are using explain from DALEX or from dplyr. If the latter is the case, just use DALEX::explain.
from dalex.
Try breakDown 1.4 from github
https://github.com/pbiecek/breakDown
Version 1.3 supports only lm and glm model while 1.4 is model agnostic
from dalex.
from dalex.
Would you provide the full example for gbm? Will be easier to debug
from dalex.
Ok, I guess that your new observation is neither a data.frame nor matrix?
from dalex.
from dalex.
n.trees
argument is required by predict.gbm
but was not correctly passed from DALEX to breakDown.
Please update both packages and following example is working for me
library(gbm)
library(DALEX)
library(breakDown)
# create a gbm model
model <- gbm(quality ~ pH + residual.sugar + sulphates + alcohol, data = wine,
distribution = "gaussian",
n.trees = 1000,
interaction.depth = 4,
shrinkage = 0.01,
n.minobsinnode = 10,
verbose = FALSE)
# make an explainer for the model
explainer_gbm <- explain(model, data = wine)
# create a new observation
new.wine <- data.frame(citric.acid = 0.35,
sulphates = 0.6,
alcohol = 12.5,
pH = 3.36,
residual.sugar = 4.8)
exp_sgn <- single_prediction(explainer_gbm, observation = new.wine, n.trees = 1000)
exp_sgn
plot(exp_sgn)
from dalex.
This fixes it, thank you. I will close the issue.
from dalex.
Related Issues (20)
- External tests fail for Ubuntu HOT 1
- predict_profile fails for penguins data because it is a tibble HOT 2
- Default color theme in DALEX HOT 1
- Add `cross_entropy` as model performance measure in `models_performance`
- thanks
- Add EDA plots to Arena in Python
- add shapr implementation to dalex
- Issue creating a DALEXtra-explainer with response-type mlr3 learners HOT 4
- Error in `predict_profile` when a Dataframe with MultiIndex is Used HOT 2
- Add support for kernelshap
- predict_parts() at dataset level HOT 6
- ability to use something other than plotly to make plots HOT 3
- Option to specify random effects? HOT 1
- PDP with 2 variables HOT 1
- update warning occurring when specifying `variable_splits`
- no applicable method for 'predict' applied to an object of class "c('randomForest.formula', 'randomForest')" HOT 1
- too many negative values of RMSE in a model_parts option HOT 2
- Differences between performance metrics between ranger model and its explain HOT 2
- error on plot predict_parts duplicate row names HOT 2
- [Python] Use `weights` in Permutation Feature Importance calculation HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from dalex.