[R] na.action in model.frame

Ravi Varadhan rvaradha at jhsph.edu
Thu Jun 5 18:01:56 CEST 2003


Dear Group:

I am trying to create a model frame from a formula for the model as 
follows:

formula <- y ~ x1 + x2 + x3
X <- model.frame(form=formula,data=mydata)

I have some missing values in some the variables, but I want them to be 
included in my model frame and to be indicated as "NA". Is there a way 
to do this?

thanks,
Ravi.




More information about the R-help mailing list