c:ma:2016:quiz04_answer
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
c:ma:2016:quiz04_answer [2016/12/26 12:56] – hkimscil | c:ma:2016:quiz04_answer [2016/12/26 13:16] – hkimscil | ||
---|---|---|---|
Line 392: | Line 392: | ||
male을 의미한다. | male을 의미한다. | ||
- | 23. | + | 24. |
plot(cats$Bwt, | plot(cats$Bwt, | ||
+ | |||
+ | 25, 26. | ||
+ | > c.lm< | ||
+ | > summary(c.lm) | ||
+ | |||
+ | Call: | ||
+ | lm(formula = cats$Hwt ~ cats$Bwt) | ||
+ | |||
+ | Residuals: | ||
+ | Min 1Q Median | ||
+ | -3.5694 -0.9634 -0.0921 | ||
+ | |||
+ | Coefficients: | ||
+ | Estimate Std. Error t value Pr(> | ||
+ | (Intercept) | ||
+ | cats$Bwt | ||
+ | --- | ||
+ | Signif. codes: | ||
+ | |||
+ | Residual standard error: 1.452 on 142 degrees of freedom | ||
+ | Multiple R-squared: | ||
+ | F-statistic: | ||
+ | |||
+ | Bwt는 Hwt에 영향을 미친다고 할 수 있다 (F(1, 142) = 259.8, | ||
+ | p < 0.001). Bwt는 Hwt의 총 분산 중 약 65%를 (0.6466) 설명 | ||
+ | 한다. | ||
+ | |||
+ | 27. | ||
+ | 0.6466 | ||
+ | |||
+ | 28. | ||
+ | 64.66% | ||
+ | |||
+ | 29. | ||
+ | abline(c.lm, | ||
+ | |||
+ | |||
+ | 30, 31. | ||
+ | |||
+ | 30,31. | ||
+ | > st.lm< | ||
+ | > summary(st.lm) | ||
+ | |||
+ | Call: | ||
+ | lm(formula = st$Murder ~ st$Population + st$Income + st$Illiteracy) | ||
+ | |||
+ | Residuals: | ||
+ | Min 1Q Median | ||
+ | -4.7846 -1.6768 -0.0839 | ||
+ | |||
+ | Coefficients: | ||
+ | | ||
+ | (Intercept) | ||
+ | st$Population 0.0002219 | ||
+ | st$Income | ||
+ | st$Illiteracy 4.1109188 | ||
+ | --- | ||
+ | Signif. codes: | ||
+ | |||
+ | Residual standard error: 2.507 on 46 degrees of freedom | ||
+ | Multiple R-squared: | ||
+ | F-statistic: | ||
+ | |||
+ | 먼저 F값의 p-value를 통해 통계적으로 유의미한 모델임을 알 수 있다. 즉, | ||
+ | Population, Income, Illiteracy가 Murder에 영향을 주는 것으로 판단 | ||
+ | 할 수 있다 (F(3,46) = 20.07, p < .001). 또한 세개의 독립변수(예측변인)은 | ||
+ | 종속변인 Murder의 총 분산 중 약 57% (0.5669)를 설명하는데 기여한다. | ||
+ | 각 변인의 기여도를 보면 Population과 Illiteracy의 t-value에 해당하느 | ||
+ | p 값은 0.05보다 작으므로 유의미한 기여를 한다고 판달 할 수 있다. 그러나, | ||
+ | Income의 경우 p 값이 0.9245로 0.05보다 커서 유의미한 기여를 한다고 볼 수 | ||
+ | 없다. | ||
+ | |||
+ | 32. | ||
+ | R square = 0.5669 | ||
+ | 종속변인인 Murder의 분산 중 독립변인인 세가지 변인(Population, | ||
+ | Income, | ||
Line 401: | Line 477: | ||
23. | 23. | ||
- | {{:c:ma:2016/plot_bwt_hwt.jpg}} | + | {{plot_bwt_hwt.jpg}} |
+ | {{plot_bwt_hwt2.jpg}} | ||
+ |
c/ma/2016/quiz04_answer.txt · Last modified: 2016/12/26 15:38 by hkimscil