1
$\begingroup$

I'm trying to build a classifier using Xgboost on some high dimensional data, the problem I'm having is that I have the prior knowledge that the output probabilities should be ascending regarding a feature(say x), but I don't know how can I make the model understand this!

For example for a data point with features Feat I want to have:

predict_proba(Feat[x=1]) <= predict_proba(Feat[X=2])

where the rest of the features are the same.

$\endgroup$

1 Answer 1

0
$\begingroup$

You can enforce such monotonicity with the monotone_constraints (hyper)parameter:

https://xgboost.readthedocs.io/en/latest/tutorials/monotonic.html
https://stackoverflow.com/questions/43076451/how-to-enforce-monotonic-constraints-in-xgboost-with-scikitlearn

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.