In: Statistics and Probability
Can hair length be used to predict the height of a person? To try to answer this, the following random subset of data were collected from our class’s data:
Hair length: 8 12 18 24 1 4 24 2
Height: 68 60 61 67 67 70 68 70
X :- Hair length
Y :- Height
ΣX = 93 ΣY =531 ΣX * Y = 6089 ΣX2 = 1705 ΣY2 = 35347
Sxx =Σ (Xi - X̅ )2 = 623.875
Syy = Σ( Yi - Y̅ )2 = 101.875
Sxy = Σ (Xi - X̅ ) * (Yi - Y̅) = -83.875
r = -0.3327
To Test :-
H0 :- ρ = 0
H1 :- ρ ≠ 0
Test Statistic :-
t = (r * √(n - 2) / (√(1 - r2))
t = ( -0.3327 * √(8 - 2) ) / (√(1 - 0.1107) )
t = -0.8642
Test Criteria :-
Reject null hypothesis if t > t(α,n-2) OR t < -t(α,n-2)
t(α/2,n-2) = t(0.05/2 , 8 - 2 ) = ± 2.4469
-2.4469 < -0.8642 < 2.4469
Result :- We fail to Reject null hypothesis
Decision based on P value
P - value = P ( t > 0.8642 ) = 0.4207
Reject null hypothesis if P value < α = 0.05 level of
significance
P - value = 0.4207 > 0.05 ,hence we fail to reject null
hypothesis
Conclusion :- We Accept H0
There is statistically no correlation between variables.
R2 = r2 = 0.1107
11.07% of variation in height is explained by hair length.
Ŷ = 67.9379 + -0.1344X
Ŷ = 67.4
Predictive Confidence Interval of
Ŷ = 67.9379 + -0.1344X
Ŷ = 67.4
t(30.645/2) = t(0.1/2) = 1.943
X̅ = (Xi / n ) = 93/8 = 11.625
90% Predictive confidence interval is (59.066 <
< 75.734)