Answer:
There is enough evidence to support the claim that there is a significant difference in the proportion of residents and commuters who prefer the switch.
Step-by-step explanation:
This is a hypothesis test for the difference between proportions.
The claim is that there is a significant difference in the proportion of residents and commuters who prefer the switch.
Then, the null and alternative hypothesis are:
![H_0: \pi_1-\pi_2=0\\\\H_a:\pi_1-\pi_2\neq 0](https://tex.z-dn.net/?f=H_0%3A%20%5Cpi_1-%5Cpi_2%3D0%5C%5C%5C%5CH_a%3A%5Cpi_1-%5Cpi_2%5Cneq%200)
The significance level is 0.05.
The sample 1 (residents), of size n1=200 has a proportion of p1=0.4.
![p_1=X_1/n_1=80/200=0.4](https://tex.z-dn.net/?f=p_1%3DX_1%2Fn_1%3D80%2F200%3D0.4)
The sample 2 (conmuters), of size n2=200 has a proportion of p2=0.6.
![p_2=X_2/n_2=120/200=0.6](https://tex.z-dn.net/?f=p_2%3DX_2%2Fn_2%3D120%2F200%3D0.6)
The difference between proportions is (p1-p2)=-0.2.
The pooled proportion, needed to calculate the standard error, is:
![p=\dfrac{X_1+X_2}{n_1+n_2}=\dfrac{80+120}{200+200}=\dfrac{200}{400}=0.5](https://tex.z-dn.net/?f=p%3D%5Cdfrac%7BX_1%2BX_2%7D%7Bn_1%2Bn_2%7D%3D%5Cdfrac%7B80%2B120%7D%7B200%2B200%7D%3D%5Cdfrac%7B200%7D%7B400%7D%3D0.5)
The estimated standard error of the difference between means is computed using the formula:
![s_{p1-p2}=\sqrt{\dfrac{p(1-p)}{n_1}+\dfrac{p(1-p)}{n_2}}=\sqrt{\dfrac{0.5*0.5}{200}+\dfrac{0.5*0.5}{200}}\\\\\\s_{p1-p2}=\sqrt{0.0013+0.0013}=\sqrt{0.0025}=0.05](https://tex.z-dn.net/?f=s_%7Bp1-p2%7D%3D%5Csqrt%7B%5Cdfrac%7Bp%281-p%29%7D%7Bn_1%7D%2B%5Cdfrac%7Bp%281-p%29%7D%7Bn_2%7D%7D%3D%5Csqrt%7B%5Cdfrac%7B0.5%2A0.5%7D%7B200%7D%2B%5Cdfrac%7B0.5%2A0.5%7D%7B200%7D%7D%5C%5C%5C%5C%5C%5Cs_%7Bp1-p2%7D%3D%5Csqrt%7B0.0013%2B0.0013%7D%3D%5Csqrt%7B0.0025%7D%3D0.05)
Then, we can calculate the z-statistic as:
![z=\dfrac{p_d-(\pi_1-\pi_2)}{s_{p1-p2}}=\dfrac{-0.2-0}{0.05}=\dfrac{-0.2}{0.05}=-4](https://tex.z-dn.net/?f=z%3D%5Cdfrac%7Bp_d-%28%5Cpi_1-%5Cpi_2%29%7D%7Bs_%7Bp1-p2%7D%7D%3D%5Cdfrac%7B-0.2-0%7D%7B0.05%7D%3D%5Cdfrac%7B-0.2%7D%7B0.05%7D%3D-4)
This test is a two-tailed test, so the P-value for this test is calculated as (using a z-table):
As the P-value (0.00008) is smaller than the significance level (0.05), the effect is significant.
The null hypothesis is rejected.
There is enough evidence to support the claim that there is a significant difference in the proportion of residents and commuters who prefer the switch.