[R] biglm and epicalc ROC curves

mah harwood262 at gmail.com
Wed Nov 10 21:30:31 CET 2010


Hello list,

I am trying to avoid "Rifying" some of my SAS code to generate ROC
plots, and the logistic.display() and lroc() functions in the epicalc
package do what I want.  However, I must generate my logistic model
with bigglm because I have 1) limited hardware, 2) ~2.5 million rows,
and 4 categorical and 2 continuous independent variables.  When I
attempt to invoke epicalc's "lroc" function on the bigglm model R
returns the error "Error in logistic.display(mod.glm) : Model not from
logistic regression".  I have replicated the issues below, using data
and the model from John Fox's car package.  Is there some editing I
can do to the list from bigglm that will allow utilization in epicalc,
or some other technique?  Thanks in advance.

library(car)
data(Mroz)
Mroz$in.wf <- ifelse(Mroz$lfp == 'yes', 1 ,0)

mod.bigglm <- bigglm(in.wf ~ k5 + k618 + age + wc + hc + lwg + inc
    ,data=Mroz
    ,family=binomial(link='logit')
)

mod.glm <- glm(in.wf ~ k5 + k618 + age + wc + hc + lwg + inc
    ,data=Mroz
    ,family=binomial(link='logit')
)

lroc(mod.glm) ## works, and generates the desired graph
lroc(mod.bigglm) ## fails with message below

Error in dimnames(x) <- dn :
  length of 'dimnames' [2] not equal to array extent



More information about the R-help mailing list