[R] How I can calculate the value of response variable

David Winsemius dwinsemius at comcast.net
Sun Jun 26 17:20:48 CEST 2016


> On Jun 26, 2016, at 3:23 AM, rezvan hatami via R-help <r-help at r-project.org> wrote:
> 
>  How I can calculate the value of response variable in a linear model of a matrix of several variables?Can somebody please answer me?
> 

   You should explain in more detail why the answer to this question is not just the `lm` function. See:

?lm
?predict.lm

    That would deliver (after suitable invocation of the `predict` function) not be the "value of the response variable" (since that would just be the values in your data), but rather the conditional expectation of the response variable given the values of the predictors.


> 
> Cheers
> Rezvan Hatami
> 	[[alternative HTML version deleted]]
> 
> ______________________________________________
> R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see
> 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.

David Winsemius
Alameda, CA, USA



More information about the R-help mailing list