On Sun, Nov 29, 2009 at 9:16 AM, Gabor Grothendieck <ggrothendi...@gmail.com
> wrote:

> By the way, if you really do want to create the formula anyways then:
>
>    ix <- 1:2
>    left <- paste(names(freeny)[ix], collapse = ",")
>    fo <- as.formula(paste("cbind(", left, ") ~ ."))
>    lm(fo, freeny)
>
> or possibly replace last line with:
>
>    eval(substitute(lm(fo, freeny))
>
> which will cause the formula to appear in the lm output.


This last line should have been:

This last line should have been:

 eval(substitute(lm(fo, freeny), list(fo = fo)))

        [[alternative HTML version deleted]]

______________________________________________
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