2
$\begingroup$

I have a continuous independent variable which is used to explain the dependent binary variable in logistic regression. The model user's requirement is to group this continuous variable to 6 bins. I use area under curve (AOC) as model performance measure. Thus I would like to bin the variable while maximizing (AOC).

I have been going through trial and error, for example trying to create almost equal number of observations in some middle buckets, but keeping top and bottom bucket separate. Since most event 1s are in the top bucket, and there are not many event 1s in bottom bucket, etc. Thus my continuous variable almost corresponds to a probability of estimating event 1, but it is not really accurate (since it is coming from some other model

What is the usual way to approach such problem? I am using R..

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.