Hi,

did you have a look at the manual "An Introduction to R"? (http://cran.r-project.org/doc/manuals/R-intro.html). Chapter "Statistical Models in R" should answer (most of) your questions concerning linear regression.

kayj wrote:

Also each x is a categorical variable with 4 categories so I have to
introduce three variables for each x

If I understood correctly what you mean (-> coding of dummy variables), this is not necessary in R. If you variable is a "factor", R does it for you automatically. If you are unhappy with the choice of reference category, please check:
?relevel

I hope this helps,
Roland

______________________________________________
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