We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I tried both R and python package. When i initialized DMatrix with dense
dmodel = xgb.DMatrix(model, label=Y.iloc[40000:].values, feature_names=dt.columns)
or sparse
dmodel = xgb.DMatrix(csc_matrix(model), label=Y.iloc[40000:].values, feature_names=dt.columns)
The training accuracy is different, is that correct? And should I always use sparse matrix?
The text was updated successfully, but these errors were encountered:
The training accuracy is different, is that correct?
Yes. "Sparse" elements are treated as "missing" by the tree booster and as zeros by the linear booster.
And should I always use sparse matrix?
Use whichever works better for you.
Sorry, something went wrong.
This was totally unexpected for me. Thanks for raising this @breakhearts
No branches or pull requests
I tried both R and python package. When i initialized DMatrix with dense
or sparse
The training accuracy is different, is that correct? And should I always use sparse matrix?
The text was updated successfully, but these errors were encountered: