Closed ruiruimufeng closed 2 years ago
Hi @ruiruimufeng thanks for reporting - could you share a minimal code & data example to reproduce?
RE importance ranking, it depends on what you want. The xrf
function returns the XGBoost & glmnet models, which you can use the respective xgboost
and glmnet
APIs of to compute importance, regularization dropout, etc.
Hey @holub008, thanks for the great package! I've been coming across errors like this occasionally while working on wrappers for your package in tidymodels/rules, and thought I'd share an example to reproduce with:
data("ames", package = "modeldata")
ames$Sale_Price <- log10(ames$Sale_Price)
xrf::xrf(
Sale_Price ~ Neighborhood + Longitude + Latitude +
Gr_Liv_Area + Central_Air,
data = ames,
family = "gaussian",
xgb_control = list(nrounds = 5, colsample_bynode = 1,
colsample_bytree = 1/5),
verbose = 0
)
#> Error in `bind_rows()`:
#> ! Can't combine `..1$feature` <character> and `..2$feature` <logical>.
Created on 2022-06-03 by the reprex package (v2.0.1)
Thanks again for your work.
Thanks @simonpcouch! I'll try to take a look at this inside a week.
I have checked all my column type, they're all numeric. After working around, following seems solved the problem.
rules } Hope this can help someone who encounterd same problem.
Q: Is there anyway to get the importance ranking?