Skip to content
Back to formatted view

Raw Message

Message-ID: <CANOgrHa6F_JiaTUZfH5=Nzf9A-FRWwbU2hApmEEJLqPQjB6dKw@mail.gmail.com>
Date: 2012-05-28T02:16:03Z
From: Mitchell Maltenfort
Subject: Unable to fit model using “lrm.fit”
In-Reply-To: <1338141188024-4631525.post@n4.nabble.com>

When I have problems like that I try the same fit using 'glm' and see
what I get.


On Sun, May 27, 2012 at 1:53 PM, irena <irena.begaj at gmail.com> wrote:
> Hi,
>
> I am running a logistic regression model using lrm library and I get the
> following error when I run the command:
>
> mod1 <- lrm(death ~ factor(score), x=T, y=T, data = env1)
> Unable to fit model using ?lrm.fit?
>
> where score is a numeric variable from 0 to 6.
>
> LRM executes fine for the following commands:
> mod1 <- lrm(death ~ score, x=T, y=T, data = env1)
>
> mod1<- lrm(death ~ ? ? ?factor(score)+
> ? ? ? ? ? ? ? ? ? ? ? factor(var1)+factor(var2)+factor(var3)+
> ? ? ? ? ? ? ? ? ? ? ? factor(var4)+factor(var5)+factor(var6)+
> ? ? ? ? ? ? ? ? ? ? ? factor(var7), x=T, y=T, data = env1)
>
> I do not understand why I get the error. I have tried to use glm and it
> works perfectly fine.
>
>
>
> --
> View this message in context: http://r.789695.n4.nabble.com/Unable-to-fit-model-using-lrm-fit-tp4631525.html
> Sent from the R help mailing list archive at Nabble.com.
>
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.