381 hypothesis testing (testing with two samples-ii) qsci 381 – lecture 31 (larson and farber,...
DESCRIPTION
381 Comparing Means with “Small” Sample Sizes (Conditions for use) To use a t-test for small (independent) samples, the following conditions must be met: The samples must be selected randomly. The samples must be independent. The data for each population must be normally distributed.TRANSCRIPT
![Page 1: 381 Hypothesis Testing (Testing with Two Samples-II) QSCI 381 – Lecture 31 (Larson and Farber, Sect…](https://reader036.vdocuments.us/reader036/viewer/2022090107/5a4d1c087f8b9ab0599f22b9/html5/thumbnails/1.jpg)
381
Hypothesis Testing(Testing with Two Samples-II)
QSCI 381 – Lecture 31(Larson and Farber, Sect 8.2)
![Page 2: 381 Hypothesis Testing (Testing with Two Samples-II) QSCI 381 – Lecture 31 (Larson and Farber, Sect…](https://reader036.vdocuments.us/reader036/viewer/2022090107/5a4d1c087f8b9ab0599f22b9/html5/thumbnails/2.jpg)
381
Comparing Two Meansz-test t-test
Samples Must be independent
Must be independent
Distribution and sample size
Both samples must have at least 30 members or the
populations must be normal with known populationstandard
deviations.
The populations must be normal (n1 or n2 can be < 30)
![Page 3: 381 Hypothesis Testing (Testing with Two Samples-II) QSCI 381 – Lecture 31 (Larson and Farber, Sect…](https://reader036.vdocuments.us/reader036/viewer/2022090107/5a4d1c087f8b9ab0599f22b9/html5/thumbnails/3.jpg)
381
Comparing Means with “Small” Sample Sizes
(Conditions for use) To use a t-test for small
(independent) samples, the following conditions must be met: The samples must be selected
randomly. The samples must be independent. The data for each population must be
normally distributed.
![Page 4: 381 Hypothesis Testing (Testing with Two Samples-II) QSCI 381 – Lecture 31 (Larson and Farber, Sect…](https://reader036.vdocuments.us/reader036/viewer/2022090107/5a4d1c087f8b9ab0599f22b9/html5/thumbnails/4.jpg)
381
Comparing Means with “Small” Sample Sizes
(The two-sample t-test) A is used to test
the difference between two population means 1 and 2 when the sample size for at least one population is less than 30.The standardized test statistic is:
1 2
1 2 1 2( ) ( )
x x
x xt
![Page 5: 381 Hypothesis Testing (Testing with Two Samples-II) QSCI 381 – Lecture 31 (Larson and Farber, Sect…](https://reader036.vdocuments.us/reader036/viewer/2022090107/5a4d1c087f8b9ab0599f22b9/html5/thumbnails/5.jpg)
381
Comparing Means with “Small” Sample Sizes
(Standard Error Specification) If the population variances are equal, then:
d.f. = If the population variances are not equal then:
d.f. = smaller of n1-1 and n2-1.
1 2
2 21 1 2 2
1 2 1 2
( 1) ( 1) 1 12x x
n s n sn n n n
1 2 2n n
1 2
2 21 2
1 2x x
s sn n
![Page 6: 381 Hypothesis Testing (Testing with Two Samples-II) QSCI 381 – Lecture 31 (Larson and Farber, Sect…](https://reader036.vdocuments.us/reader036/viewer/2022090107/5a4d1c087f8b9ab0599f22b9/html5/thumbnails/6.jpg)
381
A small survey includes two strata. The results of the survey are summarized below. Test the hypothesis that the density is the same in the two strata using =0.05. Assume the populations are normally distributed and the population variances are not equal.
Example-A-I
Stratum 1 Stratum 2
s1 = 8 s2 = 5n1=11 n2=12
1 61x 2 55x
![Page 7: 381 Hypothesis Testing (Testing with Two Samples-II) QSCI 381 – Lecture 31 (Larson and Farber, Sect…](https://reader036.vdocuments.us/reader036/viewer/2022090107/5a4d1c087f8b9ab0599f22b9/html5/thumbnails/7.jpg)
381
Example-A-II1. H0: 1=2; Ha: 1 2.2. The level of significance is 0.05, the variances are
not equal so the d.f. is 11-1=10. The rejection region is therefore |t|>2.228.
3. The variances are not equal so:
4. The standardized test statistic is:
5. The null hypothesis cannot be rejected because t is not in the rejection region.
1 2
2 2 2 21 2
1 2
8 5 2.81111 12x x
s sn n
(61 55) 0 2.1352.811
t
![Page 8: 381 Hypothesis Testing (Testing with Two Samples-II) QSCI 381 – Lecture 31 (Larson and Farber, Sect…](https://reader036.vdocuments.us/reader036/viewer/2022090107/5a4d1c087f8b9ab0599f22b9/html5/thumbnails/8.jpg)
381
Example-B-I Two areas are surveyed. One area is fished and
another is in a marine reserve. It is claimed (before the data are collected) that the density in the marine reserve will be higher than in the fished area. Assume that: a) =0.01, b) the populations are normally distributed and, c) the variances are equal.
Stratum 1 Stratum 2
s1 = 9 s2 = 10n1=11 n2=15
1 61x 2 98x
![Page 9: 381 Hypothesis Testing (Testing with Two Samples-II) QSCI 381 – Lecture 31 (Larson and Farber, Sect…](https://reader036.vdocuments.us/reader036/viewer/2022090107/5a4d1c087f8b9ab0599f22b9/html5/thumbnails/9.jpg)
381
Example-B-II1. H0: 12; Ha: 1< 2.2. The level of significance is 0.01, the variances are
equal so the d.f. is 11+15-2=24. The rejection region is therefore t>2.492.
3. The variances are equal so:
4. The standardized test statistic is:
5. The null hypothesis should be rejected because t is in the rejection region.
(98 61) 0 9.7133.809
t
1 2
2 2 2 21 1 2 2
1 2 1 2
( 1) ( 1) 1 1 (11 1)9 (15 1)10 1 1 3.8092 11 15 2 11 15x x
n s n sn n n n
![Page 10: 381 Hypothesis Testing (Testing with Two Samples-II) QSCI 381 – Lecture 31 (Larson and Farber, Sect…](https://reader036.vdocuments.us/reader036/viewer/2022090107/5a4d1c087f8b9ab0599f22b9/html5/thumbnails/10.jpg)
381
Confidence Intervals for Differences Between Means-I
If the sampling distribution for is a t-distribution and the populations have equal variances, you can construct a c-confidence interval for 1-2 using the equation:
d.f. =
1 2 1 2 1 21 2 1 2
1 1 1 1ˆ ˆ( ) ( )c cx x t x x tn n n n
1 2x x
1 2 2n n
2 21 1 2 2
1 2
( 1) ( 1)ˆ2
n s n sn n
![Page 11: 381 Hypothesis Testing (Testing with Two Samples-II) QSCI 381 – Lecture 31 (Larson and Farber, Sect…](https://reader036.vdocuments.us/reader036/viewer/2022090107/5a4d1c087f8b9ab0599f22b9/html5/thumbnails/11.jpg)
381
Confidence Intervals for Differences Between Means-II If the sampling distribution for is a t-distribution and the populations have unequal variances, you can construct a c-confidence interval for 1-2 using the equation:
d.f. = smaller of and
2 2 2 21 2 1 2
1 2 1 2 1 21 2 1 2
( ) ( )c cs s s sx x t x x tn n n n
1 2x x
1 1n 2 1n
![Page 12: 381 Hypothesis Testing (Testing with Two Samples-II) QSCI 381 – Lecture 31 (Larson and Farber, Sect…](https://reader036.vdocuments.us/reader036/viewer/2022090107/5a4d1c087f8b9ab0599f22b9/html5/thumbnails/12.jpg)
381
Example-I Find a 99% confidence interval for the
difference in density between the fished area and marine reserve in example B.
1 2 1 2 1 21 2 1 2
1 1 1 1ˆ ˆ( ) ( )c cx x t x x tn n n n
1 21 1 1 137 2.797 x9.596 37 2.797 x9.59611 15 11 15
1 226.346 47.654