Re: [R] wildcard operator

2010-05-27 Thread Dennis Murphy
Hi: On the off chance that your 9860 explanatory variables do not completely take up the 'non-y' part of your data frame, you can always write a formula string to pass to the model function. For example, form <- paste('y ~ ', paste('x', 1:10, sep = '', collapse = ' + ')) > form [1] "y ~ x1 + x2 +

Re: [R] wildcard operator

2010-05-26 Thread Erik Iverson
Eric Fail wrote: Hi Ruser As so usual I'm trying to replicate some SAS code. I wold like to know if there is a wildcard operators, as " : " in SAS, in R? When running: lm(y ~ x1 + x2 + x3 + x4 + x5 + x6 x9860, data=mydata) I would like to be able to get around it by just writing somet

Re: [R] wildcard operator

2010-05-26 Thread Jorge Ivan Velez
Hi Eric, Try lm(y ~ . , data = mydata) HTH, Jorge On Thu, May 27, 2010 at 12:58 AM, Eric Fail <> wrote: > Hi Ruser > > As so usual I'm trying to replicate some SAS code. I wold like to know if > there is a wildcard operators, as " : " in SAS, in R? > > When running: > > lm(y ~ x1 + x2 + x3 +

[R] wildcard operator

2010-05-26 Thread Eric Fail
Hi Ruser As so usual I'm trying to replicate some SAS code. I wold like to know if there is a wildcard operators, as " : " in SAS, in R? When running: lm(y ~ x1 + x2 + x3 + x4 + x5 + x6 x9860, data=mydata) I would like to be able to get around it by just writing something like this: