Presentation is loading. Please wait.

Presentation is loading. Please wait.

Review A.Null hypothesis, critical value, alpha, test statistic B.Alternative hypothesis, critical region, p-value, independent variable C.Null hypothesis,

Similar presentations


Presentation on theme: "Review A.Null hypothesis, critical value, alpha, test statistic B.Alternative hypothesis, critical region, p-value, independent variable C.Null hypothesis,"— Presentation transcript:

1 Review A.Null hypothesis, critical value, alpha, test statistic B.Alternative hypothesis, critical region, p-value, independent variable C.Null hypothesis, critical region, p-value, test statistic D.Alternative hypothesis, critical value, alpha, independent variable Sampling Distribution under 1 2 3 4

2 Review The average person can hold his or her breath for 47 seconds. Curious how you compare to this value, you time yourself ten times, calculate your mean, and do a t-test. Which of these would be a 2-tailed alternative hypothesis? A.Your mean time is 47 seconds B.Your mean time is different from 47 seconds C.Your mean time is greater than 47 seconds D.Your mean time is less than 47 seconds

3 Review A pharmaceutical company regularly runs experiments to test whether candidate drugs do what they’re supposed to. Their experiments use an alpha level of.01. Of all the drugs that really do work, 20% are mistakenly abandoned because the experiment fails to find evidence that they work. What is the power of the company’s experiments? A.1% B.20% C.80% D.99%

4 Two-sample t-tests 10/14

5 +14 M = 14 M = -36.3 -27 -41 Flood

6 Independent-samples t-test Often interested in whether two groups have same mean – Experimental vs. control conditions – Comparing learning procedures, with vs. without drug, lesions, etc. – Men vs. women, depressed vs. not Comparison of two separate populations – Population A, sample A of size n A, mean M A estimates  A – Population B, sample B of size n B, mean M B estimates  B –  A =  B ? Example: maze times – Rats without hippocampus: Sample A = [37, 31, 27, 46, 33] – With hippocampus: Sample B = [43, 26, 35, 31, 28] – M A = 34.8, M B = 32.6 – Is difference reliable?  A >  B ? Null hypothesis:  A =  B – No assumptions of what each is (e.g.,  A = 10,  B = 10) Alternative Hypothesis:  A ≠  B

7 Finding a Test Statistic Goal: Define a test statistic for deciding  A =  B vs.  A ≠  B Constraints (apply to all hypothesis testing): – Must be function of data (both samples) – Sampling distribution must be fully determined by H 0 Can only assume  A =  B Can’t depend on  A or  B separately, or on  – Alternative hypothesis should predict extreme values Statistic should measure deviation from  A =  B so that if  A ≠  B, we’ll be able to reject H 0 Answer (preview): – Based on M A – M B (just like M –  0 for one-sample t-test) –.–. – (M A – M B ) has Normal distribution – Standard error has (modified) chi-square distribution – Ratio has t distribution

8 Likelihood Function for M A – M B Central Limit Theorem Distribution of M A – M B – Subtract the means: E(M A – M B ) = E(M A ) – E(M B ) =  –  = 0 – Add the variances: –.–. Just divide by standard error? –.–. – Same problem as before: We don’t know  – Need to estimate from data

9 Estimating  Already know best estimator for one sample Could just use one sample or the other – s A or s B – Works, but not best use of the data Combining s A and s B – Both come from averages of (X – M) 2 – Average them all together: Degrees of freedom – (n A – 1) + (n B – 1) = n A + n B – 2

10 Independent-Samples t Statistic Difference between sample means Typical difference expected by chance Estimate of   Degrees of freedom Sum of squared deviations Variance from M A Variance from M B Variance of M A – M B Mean Square; estimates  

11 Steps of Independent Samples t-test 1.State clearly the two hypotheses 2.Determine null and alternative hypotheses H 0 :  A =  B H 1 :  A ≠  B 3.Compute the test statistic t from the data. Difference between sample means, divided by standard error 4.Determine likelihood function for test statistic according to H 0 t distribution with n A + n B – 2 degrees of freedom 5.Choose alpha level 6.Find critical value 7a.t beyond t crit : Reject null hypothesis,  A ≠  B 7b.t within t crit : Retain null hypothesis,  A =  B

12 XX-MAX-MA (X-MA)2(X-MA)2 372.24.84 31-3.814.44 27-7.860.84 4611.2125.44 33-1.83.24  A (X-M A ) 2 = 208.80 XX-MBX-MB (X-MB)2(X-MB)2 4310.4108.16 26-6.643.56 352.45.76 31-1.62.56 28-4.621.16  B (X-M B ) 2 = 181.20 Example – Rats without hippocampus: Sample A = [37, 31, 27, 46, 33] – With hippocampus: Sample B = [43, 26, 35, 31, 28] – M A = 34.8, M B = 32.6, M A – M B = 2.2 – df = n A + n B – 2 = 5 + 5 – 2 = 8 t8t8 t crit = 1.86

13 Mean Squares Average of squared deviations Used for estimating variance Population Sample Population variance,  2 Also estimates  2 Two samples Sample variance, s 2 Estimates  2

14 Degrees of Freedom Applies to any sum-of-squares type formula Tells how many numbers are really being added – n = 2: only one number – In general: one number determined by the rest Every statistic in formula that’s based on X removes 1 df – M, M A, M B – Algebraically rewriting formula in terms of only X results in fewer summands I will always tell you the rule for df for each formula To get Mean Square, divide sum of squares by df Sampling distribution of a statistic depends on its degrees of freedom –  2, t, F XX – M(X – M) 2 3-24 724

15 Independent vs. Paired Samples Independent-samples t-test assumes no relation between Sample A and Sample B – Unrelated subjects, randomly assigned – Necessary for standard error of (M A – M B ) to be correct Sometimes samples are paired – Each score in Sample A goes with a score in Sample B – Before vs. after, husband vs. wife, matched controls – Paired-samples t-test

16 Paired-samples t-test Data are pairs of scores, (X A, X B ) – Form two samples, X A and X B – Samples are not independent Same null hypothesis as with independent samples –  A =  B – Equivalent to mean(X A – X B ) = 0 Approach – Compute difference scores, X diff = X A – X B – One-sample t-test on difference scores, with  0 = 0

17 Example Breath holding underwater vs. on land – 8 subjects – Water: X A = [54, 98, 67, 143, 82, 91, 129, 112] – Land:X B = [52, 94, 69, 139, 79, 86, 130, 110] Difference: X diff = [2, 4, -2, 4, 3, 5, -1, 2] Critical value > qt(.025,7,lower.tail=FALSE) [1] 2.364624 Reliably longer underwater Mean: Standard Error: Mean Square:Test Statistic:

18 Comparison of t-tests SamplesDatatStandard ErrorMean Squaredf One Xn - 1 2-Indep. X A, X B n A + n B – 2 2-Paired X diff = X A - X B n - 1

19 Review A study of adult and infant speech observes brief interactions between 10 two- year-olds and their mothers. For each dyad, we record the number of words spoken by the parent and by the child. The question is who speaks more on average. What type of t-test should be used to analyze the data? A.One-sample t-test B.Independent-samples t-test C.Paired-samples t-test D.Depends on your choice of null hypothesis

20 Review Find the mean difference score, M diff, from the data below. A.1.8 B.4.4 C.36.1 D.72.2 Dyad 12345678910 Parent27442932475324593817 Child33402533415921503416

21 Review Now calculate t. A.0.12 B.0.37 C.1.16 D.2.72 Dyad 12345678910 Parent27442932475324593817 Child33402533415921503416 Diff-6446-63941 M diff = 1.8 s diff = 4.9


Download ppt "Review A.Null hypothesis, critical value, alpha, test statistic B.Alternative hypothesis, critical region, p-value, independent variable C.Null hypothesis,"

Similar presentations


Ads by Google