Anda di halaman 1dari 10

Tugas korelasi BMI, BB, Tekanan darah (dengan BMI sebagai variabel Dependent)

Contoh data :
BMI
17.8
17.9
17.9
18.1
18.2
18.3
18.4
18.4
18.4
18.5
18.6
18.7
19.2
19.4
19.4
19.5
19.6
19.7
19.9
20.1
20.5
20.7
20.7
20.8
20.9
20.9
21.2
21.3
21.3
21.4
21.8
21.9
22.3
22.4
22.4
28.7
28.8
27.9
29.9
23.2

sistol

diastol
110
110
110
110
120
120
120
90
120
120
120
120
120
120
120
120
120
120
120
120
120
90
120
120
120
120
120
120
120
120
120
120
120
120
120
140
150
140
140
120

berat
badan
70
70
70
70
75
75
80
60
80
80
80
80
80
80
80
80
80
80
80
80
80
60
80
80
80
80
80
80
80
80
80
80
80
80
80
90
90
90
90
80

48
50
43
52
53
60
67
66
68
69
70
71
74
69
70
66
64
65
63
57
55
45
56
54
52
60
70
66
64
62
61
54
64
77
76
80
82
78
82
81

23.5
23.6
23.7
23.8
25.1
25.2
25.2
25.2
25.5
25.8
25.9
26.8

120
120
120
120
120
120
120
120
120
120
120
120

80
80
80
80
80
80
80
80
80
80
80
80

76
77
61
63
62
50
62
61
68
73
61
64

Pearson's product-moment correlation


data: Dataset$BMI and Dataset$sistol
t = 5.4491, df = 50, p-value = 1.55e-06
alternative hypothesis: true correlation is not equal to 0
95 percent confidence interval:
0.4049631 0.7571751
sample estimates:
cor
0.6104048
correlation coefficient = 0.61, 95% CI 0.405-0.757, p.value = 1.55e-06

Pearson's product-moment correlation


data: Dataset$BMI and Dataset$diastol
t = 5.437, df = 50, p-value = 1.617e-06
alternative hypothesis: true correlation is not equal to 0
95 percent confidence interval:
0.4038255 0.7565942
sample estimates:
cor
0.6095508
correlation coefficient = 0.61, 95% CI 0.404-0.757, p.value = 1.62e-06
3

Pearson's product-moment correlation


data: Dataset$berat.badan and Dataset$BMI
t = 3.6781, df = 50, p-value = 0.0005746
alternative hypothesis: true correlation is not equal to 0
95 percent confidence interval:
0.2157340 0.6522285
sample estimates:
cor
0.461466
correlation coefficient = 0.461, 95% CI 0.216-0.652, p.value = 0.000575
4

> #####Linear regression#####


Call:
lm(formula = berat.badan ~ BMI, data = Dataset)
Residuals:
Min

1Q Median

3Q

Max

-18.9622 -7.0024 0.5209 7.6080 14.8094


Coefficients:
Estimate

Std. Error

t value

Pr(>|t|)

(Intercept)

34.0410

8.3061

4.098

0.000153 ***

BMI

1.3858

0.3768

3.678

0.000575 ***

0.001 '**'

0.01 '*'

0.05 '.' 0.1 ' ' 1

--Signif. codes: 0 '***'

Residual standard error: 8.682 on 50 degrees of freedom


Multiple R-squared: 0.213, Adjusted R-squared: 0.1972
F-statistic: 13.53 on 1 and 50 DF, p-value: 0.0005746
> ###variance inflation factors
> colnames(res$coefficients) <- gettext(domain="R-RcmdrPlugin.EZR",
+ colnames(res$coefficients))
> res$coefficients
Estimate

Std. Error

t value

Pr(>|t|)

(Intercept)

34.04101

8.3061422

4.098294

0.000152553

BMI

1.38576

0.3767594

3.678103

0.000574607

Call:
lm(formula = sistol ~ BMI, data = Dataset)
Residuals:
Min

1Q Median

3Q

Max

-27.874 -3.030 1.084 4.384 18.059


Coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) 81.9250

7.0262 11.660 7.15e-16 ***


7

BMI

1.7367

0.3187 5.449 1.55e-06 ***

--Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
Residual standard error: 7.344 on 50 degrees of freedom
Multiple R-squared: 0.3726, Adjusted R-squared: 0.36
F-statistic: 29.69 on 1 and 50 DF, p-value: 1.55e-06
Estimate Std. Error t value

Pr(>|t|)

(Intercept) 81.925049 7.0262297 11.659888 7.152228e-16


BMI

1.736664 0.3187037 5.449148 1.549793e-06

Call:
lm(formula = diastol ~ BMI, data = Dataset)
Residuals:
Min

1Q Median

3Q

Max

-17.860 -2.545 1.188 3.226 4.575


Coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) 55.9436
BMI

1.0587

4.2931 13.031 < 2e-16 ***


0.1947 5.437 1.62e-06 ***

--Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
Residual standard error: 4.487 on 50 degrees of freedom
Multiple R-squared: 0.3716, Adjusted R-squared: 0.359
F-statistic: 29.56 on 1 and 50 DF, p-value: 1.617e-06
Estimate Std. Error t value

Pr(>|t|)

(Intercept) 55.943566 4.2930541 13.031181 1.063847e-17


BMI

1.058745 0.1947292 5.437012 1.617487e-06

10

Anda mungkin juga menyukai