On Jun 17, 2009, at 1:03 PM, David Winsemius wrote:


On Jun 17, 2009, at 12:35 PM, amor Gandhi wrote:

Hello,

I am using
mod1 <- lrm(y~x1+x2,na.action=na.pass,method="lrm.fit")
summary(mod1)
and I've got the following error:
Error in summary.Design(mod1) : adjustment values not defined here or with datadist for x1 x2


Several of the useful features of the Design/Hmisc function set depend on having the datadist option defined. My encounters with failing to meet that expectation usually occur when I go to plot an interaction surface with plot.Design(). In my experience some functions work better if the data is passed in a dataframe. but the docs for datadist do not imply this to be a requirement.

What do you get if you try:

df1 <- data.frame(y=y, x1=x1, x2=x2)  # might not be necessary
dd=datadist(df) # might work with datadist(y,x1,x2)
            ^df1^
options(datadist="dd")
mod1 <- lrm(y~x1+x2,na.action=na.pass, data=df1, method="lrm.fit")
# or  mod1 <- lrm(y~x1+x2,na.action=na.pass, method="lrm.fit")

summary(mod1)

--

David Winsemius, MD
Heritage Laboratories
West Hartford, CT

______________________________________________
R-help@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.

Reply via email to