Re: [R] Goodness of fit of binary logistic model

2011-08-06 Thread Paul Smith
Thanks, Frank. As a rule, I provide an example in my first post. However, in this case, the data are confidential, and I was not allowed to provide you those data. Moreover, I thought that I was not able to generate data exhibiting the reported problem. Paul On Sat, Aug 6, 2011 at 3:27 PM, Frank

Re: [R] Goodness of fit of binary logistic model

2011-08-06 Thread Frank Harrell
Exactly right Peter. Thanks. There should be some way for me to detect such situations so as to not result in an impressive P-value. Ideas welcomed! This is a great example why users should post a toy example on the first posting, as we can immediately see that this model MUST fit the data, so

Re: [R] Goodness of fit of binary logistic model

2011-08-05 Thread peter dalgaard
On Aug 5, 2011, at 23:16 , Paul Smith wrote: > Thanks, Frank. The following piece of code generate data, which > exhibit the problem I reported: > > - > set.seed(123) > intercept = -1.32 > beta = 1.36 > xtest = rbinom(1000,1,0.5) > linpred = intercept + xt

Re: [R] Goodness of fit of binary logistic model

2011-08-05 Thread Paul Smith
Thanks, Frank. The following piece of code generate data, which exhibit the problem I reported: - set.seed(123) intercept = -1.32 beta = 1.36 xtest = rbinom(1000,1,0.5) linpred = intercept + xtest*beta prob = exp(linpred)/(1 + exp(linpred)) runis = runif(100

Re: [R] Goodness of fit of binary logistic model

2011-08-05 Thread Frank Harrell
Please provide the data or better the R code for simulating the data that shows the problem. Then we can look further into this. Frank - Frank Harrell Department of Biostatistics, Vanderbilt University -- View this message in context: http://r.789695.n4.nabble.com/Goodness-of-fit-of-binary-l

Re: [R] Goodness of fit of binary logistic model

2011-08-05 Thread David Winsemius
On Aug 5, 2011, at 2:29 PM, Paul Smith wrote: On Fri, Aug 5, 2011 at 7:07 PM, David Winsemius > wrote: I have just estimated this model: --- Logistic Regression Model lrm(formula = Y ~ X16, x = T, y = T) Model Likelihood

Re: [R] Goodness of fit of binary logistic model

2011-08-05 Thread David Winsemius
On Aug 5, 2011, at 2:29 PM, Paul Smith wrote: On Fri, Aug 5, 2011 at 7:07 PM, David Winsemius > wrote: I have just estimated this model: --- Logistic Regression Model lrm(formula = Y ~ X16, x = T, y = T) Model Likelihood

Re: [R] Goodness of fit of binary logistic model

2011-08-05 Thread Paul Smith
On Fri, Aug 5, 2011 at 7:07 PM, David Winsemius wrote: >> I have just estimated this model: >> --- >> Logistic Regression Model >> >> lrm(formula = Y ~ X16, x = T, y = T) >> >>                  Model Likelihood    

Re: [R] Goodness of fit of binary logistic model

2011-08-05 Thread David Winsemius
On Aug 5, 2011, at 12:53 PM, Paul Smith wrote: On Fri, Aug 5, 2011 at 5:35 PM, David Winsemius > wrote: I have just estimated this model: --- Logistic Regression Model lrm(formula = Y ~ X16, x = T, y = T) Model Likeliho

Re: [R] Goodness of fit of binary logistic model

2011-08-05 Thread Paul Smith
On Fri, Aug 5, 2011 at 5:35 PM, David Winsemius wrote: I have just estimated this model: --- Logistic Regression Model lrm(formula = Y ~ X16, x = T, y = T)                   Model Likelihood     Discriminati

Re: [R] Goodness of fit of binary logistic model

2011-08-05 Thread David Winsemius
On Aug 5, 2011, at 12:21 PM, Paul Smith wrote: On Fri, Aug 5, 2011 at 4:54 PM, David Winsemius > wrote: I have just estimated this model: --- Logistic Regression Model lrm(formula = Y ~ X16, x = T, y = T) Model Likelih

Re: [R] Goodness of fit of binary logistic model

2011-08-05 Thread Paul Smith
On Fri, Aug 5, 2011 at 4:54 PM, David Winsemius wrote: >> I have just estimated this model: >> --- >> Logistic Regression Model >> >> lrm(formula = Y ~ X16, x = T, y = T) >> >>                    Model Likelihood     Discrimination    Rank Di

Re: [R] Goodness of fit of binary logistic model

2011-08-05 Thread David Winsemius
On Aug 5, 2011, at 9:47 AM, Paul Smith wrote: Dear All, I have just estimated this model: --- Logistic Regression Model lrm(formula = Y ~ X16, x = T, y = T) Model Likelihood DiscriminationRank Discrim.

[R] Goodness of fit of binary logistic model

2011-08-05 Thread Paul Smith
Dear All, I have just estimated this model: --- Logistic Regression Model lrm(formula = Y ~ X16, x = T, y = T) Model Likelihood DiscriminationRank Discrim. Ratio TestIndexes