Re: [Rd] formula(CO2)

From: Kevin Wright <>
Date: Tue, 17 Jul 2007 10:14:47 -0500

About a month ago I had a similar issue related to 'formula':

In summary:

In S-Plus, the help for says: This is a method for the function formula() for objects inheriting from class data.frame. If object is a model frame, the formula for the model frame is returned, otherwise a formula is deduced from the names of object. The first name is taken to be the response, and all the remaining names are pasted together additively.

In R, the help for is aliased to the help for formula, but does not clearly document the usage with data.frames.


On 7/16/07, Gabor Grothendieck <> wrote:
> The formula attribute of the builtin CO2 dataset seems a bit strange:
> > formula(CO2)
> Plant ~ Type + Treatment + conc + uptake
> What is one supposed to do with that? Certainly its not suitable for
> input to lm and none of the examples in ?CO2 use the above.
> ______________________________________________
> mailing list
> mailing list Received on Tue 17 Jul 2007 - 16:32:57 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Tue 17 Jul 2007 - 18:36:44 GMT.

Mailing list information is available at Please read the posting guide before posting to the list.