0

I am looking to do credit scoring using logistic regression in R and I am stumped on this...

If I have a categorical variable "Residence" with factors "Own", "Rent" and "Other" and I want to set the weight of "Other" to zero so that it is neutral in the model what would be the best way to do this in glm in R?

We can do this manually using Fico Model Builder but I'm not sure how to do it in R.

Thanks.

Dirk Calloway
  • 2,569
  • 4
  • 23
  • 34

1 Answers1

0

If you want to omit cases with Residence=="Other" then use the subset argument to glm().

 logmod <- glm(binaryvar ~ covar1 + Residence, data=dat, 
               subset= Residence =="Other", family="binomial")
IRTFM
  • 258,963
  • 21
  • 364
  • 487
  • Not looking to omit all the cases with "Other". I'm looking to pre-set the weight of it to zero. – Dirk Calloway Aug 13 '13 at 07:08
  • You need to explain how that is different than omitting the cases. (Perhaps your understanding of the term "weight" is different than is generally used in statistics. If you want "Other" to be the reference level to which other effects are compared then you need to used different terminology.) – IRTFM Aug 13 '13 at 16:12
  • I think you are right... I am looking into the reference weight. – Dirk Calloway Aug 14 '13 at 13:32