[R] FW: multivariate regression
Mark Difford
mark_difford at yahoo.co.uk
Mon Feb 7 09:26:35 CET 2011
Deniz,
>> There are 3 F statistics, R2 and p-values. But I want just one R2 and
>> pvalue for my multivariate
>> regression model.
Which is as it should.
Maybe the following will help, but we are making the dependent variables the
independent variables, which may or may not be what you really have in mind.
(Otherwise, as Uwe has said, you need to specify how "this one R^2 / p-value
should be defined from your point of view".)
> summary(lm(X~Y))
Call:
lm(formula = X ~ Y)
Residuals:
Min 1Q Median 3Q Max
-20.329 -9.770 0.271 11.167 18.986
Coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) 65.663 31.464 2.087 0.082 .
Y1 -4.232 4.616 -0.917 0.395
Y2 6.846 4.181 1.637 0.153
Y3 -4.145 4.616 -0.898 0.404
---
Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
Residual standard error: 16.64 on 6 degrees of freedom
Multiple R-squared: 0.3641, Adjusted R-squared: 0.04622
F-statistic: 1.145 on 3 and 6 DF, p-value: 0.4041
--
View this message in context: http://r.789695.n4.nabble.com/multivariate-regression-tp3260141p3263712.html
Sent from the R help mailing list archive at Nabble.com.
More information about the R-help
mailing list