Factors of Facility Condition
Sportand Recreational Facilities
Chien-Yao Lin (s3790516)
Mingjin Pan (s3742684)
Last updated: 27 October, 2019
Hypothesis Testing
- Because no more than 25% of the cells have expected counts below 5, we can use the Chi-square test of association to test the following hypothesis.
- \(H_0:\) There is no association in the population between FacilityCondition and StreetType.
- \(H_A:\) There is an association in the population between FacilityCondition and StreetType.
chi2_con_street <- chisq.test(table(df$FacilityCondition, df$StreetType))
chi2_con_street
##
## Pearson's Chi-squared test
##
## data: table(df$FacilityCondition, df$StreetType)
## X-squared = 12.446, df = 12, p-value = 0.4105
- Because \(p\)-value = 0.4105 > \(\alpha\) = 0.05, we fail to reject \(H_0:\) There is no association in the population between FacilityCondition and StreetType. As a result, there is no sufficient statistically significant evidence to support \(H_A\).
Hypthesis Testing Cont.
- Because no more than 25% of the cells have expected counts below 5, we can use the Chi-square test of association to test the following hypothesis.
- \(H_0:\) There is no association in the population between FacilityCondition and FacilityAge.
- \(H_A:\) There is an association in the population between FacilityCondition and FacilityAge.
chi2_con_age <- chisq.test(table(df$FacilityCondition, df$FacilityAge))
chi2_con_age
##
## Pearson's Chi-squared test
##
## data: table(df$FacilityCondition, df$FacilityAge)
## X-squared = 1660.1, df = 16, p-value < 2.2e-16
Because \(p\)-value < 2.2e-16 < \(\alpha\) = 0.05 and , we reject \(H_0\). As a result, the test is statistically significant to support \(H_A:\) There is an association in the population between FacilityCondition and FacilityAge.