Multivariate multiple regression

TODO

  • link to regressionDiag, anovaSStypes

Install required packages

car

Model fit


Call:
lm(formula = cbind(Y1, Y2) ~ X1 + X2 + X3, data = dfRegr)

Coefficients:
             Y1        Y2      
(Intercept)  23.08395  16.32336
X1            0.12078  -0.03185
X2           -0.24223  -0.31782
X3           -0.41913   0.19836
(Intercept)          X1          X2          X3 
 23.0839518   0.1207848  -0.2422273  -0.4191290 
(Intercept)          X1          X2          X3 
16.32335532 -0.03185035 -0.31782397  0.19836272 

Coefficient tests and overall model test

Type I sum of squares

          Df Hotelling-Lawley approx F num Df den Df    Pr(>F)    
X1         1            0.760    36.12      2     95 2.158e-12 ***
X2         1            5.910   280.74      2     95 < 2.2e-16 ***
X3         1           35.086  1666.58      2     95 < 2.2e-16 ***
Residuals 96                                                      
---
Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

No possibility to use confint() for multivariate models.

Type II/III sum of squares

Since no interaction is present in the model, SS type II and III are equivalent here.


Type II MANOVA Tests: Pillai test statistic
   Df test stat approx F num Df den Df Pr(>F)    
X1  1   0.04655     2.32      2     95 0.1039    
X2  1   0.86848   313.66      2     95 <2e-16 ***
X3  1   0.97229  1666.58      2     95 <2e-16 ***
---
Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

Detach (automatically) loaded packages (if possible)

Get the article source from GitHub

R markdown - markdown - R code - all posts