r:factorial_anova
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| r:factorial_anova [2026/04/28 13:16] – hkimscil | r:factorial_anova [2026/04/28 13:32] (current) – [output interpretation] hkimscil | ||
|---|---|---|---|
| Line 707: | Line 707: | ||
| * drg2의 운동유무, | * drg2의 운동유무, | ||
| {{.: | {{.: | ||
| + | < | ||
| + | > m.lm <- (lm(y~a*b, data = dat)) | ||
| + | > summary(m.lm) | ||
| + | Call: | ||
| + | lm(formula = y ~ a * b, data = dat) | ||
| + | |||
| + | Residuals: | ||
| + | Min 1Q Median | ||
| + | -1.9469 -0.4908 -0.1742 | ||
| + | |||
| + | Coefficients: | ||
| + | | ||
| + | (Intercept) | ||
| + | adrg2 0.8050 | ||
| + | adrg3 0.6943 | ||
| + | bexerc | ||
| + | adrg2: | ||
| + | adrg3: | ||
| + | --- | ||
| + | Signif. codes: | ||
| + | 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 | ||
| + | |||
| + | Residual standard error: 1.016 on 24 degrees of freedom | ||
| + | Multiple R-squared: | ||
| + | F-statistic: | ||
| + | |||
| + | > anova(m.lm) | ||
| + | Analysis of Variance Table | ||
| + | |||
| + | Response: y | ||
| + | Df Sum Sq Mean Sq F value Pr(> | ||
| + | a 2 12.566 | ||
| + | b 1 12.107 12.1069 11.7176 0.0022274 ** | ||
| + | a:b 2 25.740 12.8699 12.4561 0.0001948 *** | ||
| + | Residuals 24 24.797 | ||
| + | --- | ||
| + | Signif. codes: | ||
| + | 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 | ||
| + | > | ||
| + | |||
| + | > ss.tot <- sum(anova(m.lm)[2]) | ||
| + | > ss.a <- anova(m.lm)[[2]][1] | ||
| + | > ss.b <- anova(m.lm)[[2]][2] | ||
| + | > ss.ab <- anova(m.lm)[[2]][3] | ||
| + | > ss.bet <- ss.a + ss.b + ss.ab | ||
| + | > ss.bet | ||
| + | [1] 50.41308 | ||
| + | > ss.tot | ||
| + | [1] 75.21048 | ||
| + | > ss.bet / ss.tot | ||
| + | [1] 0.6702933 | ||
| + | > | ||
| + | |||
| + | </ | ||
r/factorial_anova.1777382203.txt.gz · Last modified: by hkimscil
