R-beta: formula() and model formulae
Mike Meyer
mikem at stat.cmu.edu
Tue May 6 17:21:39 CEST 1997
Several bugs (no solutions, yet). These might be well known.
1) If one does, e.g., mymod <- lm(y ~ x); formula(mymod)
then one does not get back the formula (one gets, Error: invalid formula)
2) if x is of mode numeric, then the model formula
mymod <- lm(y ~ x + x^2)
is not processed as S would do it. The model is fit ignoring the x^2 term,
however mymod$call includes the x^2 term. This seems to be a bug (or maybe
feature) in applying model formulae operators to numeric quantities. I expect
(from experience with S) that x^2 will be interpreted as a math operator.
Whatever the right thing to do is, it needs to be documented.
Regards, --Mike
Mike Meyer, Department of Statistics, Carnegie Mellon University
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
More information about the R-help
mailing list