[R] meaning of glm(value ~ .,

onyourmark william108 at gmail.com
Fri Jun 19 15:00:37 CEST 2009


I am trying to build a glm model with many inputs.
I saw the following code in Rattle
crs$glm <- glm(value ~ ., data=crs$dataset[,c(1:59,922)],
family=binomial(link="logit"))

I am not clear about what 

value ~ .

means and also, I see 

data=crs$dataset[,c(1:59,922)] 

I have read that the data argument is optional here
"an optional data frame, list or environment (or object coercible by
as.data.frame to a data frame) containing the variables in the model. If not
found in data, the variables are taken from environment(formula), typically
the environment from which glm is called"

when they say "data", is that meant to include the dependent variable as
well. In other words,
in the above statement 'value' is the dependent variable and it is also
column 922 in the data set.
Is this correct?
correct
Thank you.

-- 
View this message in context: http://www.nabble.com/meaning-of--glm%28value-%7E-.%2C-tp24110747p24110747.html
Sent from the R help mailing list archive at Nabble.com.




More information about the R-help mailing list