Skip to content
Prev 60094 / 398502 Next

2k-factorial design with 10 parameters

On 30 Nov 2004 at 12:59, Sven wrote:

            
Hi Sven

from
?lm

The specification 'first*second'
     indicates the _cross_ of 'first' and 'second'.  This is the same
     as 'first + second + first:second'

and from

?formula

## Create a formula for a model with a large number of variables:
     xnam <- paste("x", 1:25, sep="")
     (fmla <- as.formula(paste("y ~ ", paste(xnam, collapse= "+"))))

If you change 1:25 to 1:10 and collapse to * and use fmla in your 
model you will get what you want (I suppose). But I woder if it 
has any sense.

Cheers
Petr
Petr Pikal
petr.pikal at precheza.cz