Two sample Test. Paired Data : Δ = 0. Lecture 3: Comparison of Means. d s d where is the sample average of the differences and is the

Similar documents
Data Processing Techniques

Sta$s$cs for Genomics ( )

T.I.H.E. IT 233 Statistics and Probability: Sem. 1: 2013 ESTIMATION AND HYPOTHESIS TESTING OF TWO POPULATIONS

Chapter 5: HYPOTHESIS TESTING

Power of a test. Hypothesis testing

LAB 2. HYPOTHESIS TESTING IN THE BIOLOGICAL SCIENCES- Part 2

280 CHAPTER 9 TESTS OF HYPOTHESES FOR A SINGLE SAMPLE Tests of Statistical Hypotheses

Lecture 9. ANOVA: Random-effects model, sample size

ECO220Y Review and Introduction to Hypothesis Testing Readings: Chapter 12

Some Review and Hypothesis Tes4ng. Friday, March 15, 13

Linear Regression and Correla/on. Correla/on and Regression Analysis. Three Ques/ons 9/14/14. Chapter 13. Dr. Richard Jerz

Linear Regression and Correla/on

Outline. PubH 5450 Biostatistics I Prof. Carlin. Confidence Interval for the Mean. Part I. Reviews

Sta$s$cal Significance Tes$ng In Theory and In Prac$ce

LECTURE 12 CONFIDENCE INTERVAL AND HYPOTHESIS TESTING

The legacy of Sir Ronald A. Fisher. Fisher s three fundamental principles: local control, replication, and randomization.

T- test recap. Week 7. One- sample t- test. One- sample t- test 5/13/12. t = x " µ s x. One- sample t- test Paired t- test Independent samples t- test

STAT Chapter 8: Hypothesis Tests

ME3620. Theory of Engineering Experimentation. Spring Chapter IV. Decision Making for a Single Sample. Chapter IV

ECO220Y Hypothesis Testing: Type I and Type II Errors and Power Readings: Chapter 12,

One- factor ANOVA. F Ra5o. If H 0 is true. F Distribu5on. If H 1 is true 5/25/12. One- way ANOVA: A supersized independent- samples t- test

REGRESSION AND CORRELATION ANALYSIS

Quantitative Methods for Economics, Finance and Management (A86050 F86050)

Garvan Ins)tute Biosta)s)cal Workshop 16/7/2015. Tuan V. Nguyen. Garvan Ins)tute of Medical Research Sydney, Australia

Relating Graph to Matlab

STAT 135 Lab 9 Multiple Testing, One-Way ANOVA and Kruskal-Wallis

How do we compare the relative performance among competing models?

Sample Size Determination

Statistics for IT Managers

First we look at some terms to be used in this section.

Comparing Systems Using Sample Data

Chapter 7: Hypothesis Testing

PHP2510: Principles of Biostatistics & Data Analysis. Lecture X: Hypothesis testing. PHP 2510 Lec 10: Hypothesis testing 1

Wednesday, 20 November 13. p<0.05

Looking at the Other Side of Bonferroni

Sampling Distributions: Central Limit Theorem

Multiple Testing. Gary W. Oehlert. January 28, School of Statistics University of Minnesota

Business Statistics. Lecture 5: Confidence Intervals

On Assumptions. On Assumptions

Lectures 5 & 6: Hypothesis Testing

Questions 3.83, 6.11, 6.12, 6.17, 6.25, 6.29, 6.33, 6.35, 6.50, 6.51, 6.53, 6.55, 6.59, 6.60, 6.65, 6.69, 6.70, 6.77, 6.79, 6.89, 6.

Chapter Three. Hypothesis Testing

Review: General Approach to Hypothesis Testing. 1. Define the research question and formulate the appropriate null and alternative hypotheses.

Lecture 9 Two-Sample Test. Fall 2013 Prof. Yao Xie, H. Milton Stewart School of Industrial Systems & Engineering Georgia Tech

Hypothesis Testing and Confidence Intervals (Part 2): Cohen s d, Logic of Testing, and Confidence Intervals

Hypothesis tests

Uni- and Bivariate Power

Section 9.4. Notation. Requirements. Definition. Inferences About Two Means (Matched Pairs) Examples

Differen'al Privacy with Bounded Priors: Reconciling U+lity and Privacy in Genome- Wide Associa+on Studies

Lecture 30. DATA 8 Summer Regression Inference

Introduc)on to RNA- Seq Data Analysis. Dr. Benilton S Carvalho Department of Medical Gene)cs Faculty of Medical Sciences State University of Campinas

Microarray Preprocessing

Power of a hypothesis test

Review of Statistics 101

The t-test Pivots Summary. Pivots and t-tests. Patrick Breheny. October 15. Patrick Breheny Biostatistical Methods I (BIOS 5710) 1/18

Multiple comparisons - subsequent inferences for two-way ANOVA

Statistical Process Control (contd... )

Hypothesis testing: Steps

Exam 2 (KEY) July 20, 2009

Performance Evaluation and Comparison

Business Statistics. Lecture 10: Course Review

Notes for Week 13 Analysis of Variance (ANOVA) continued WEEK 13 page 1

Statistical Applications in Genetics and Molecular Biology

Statistics: CI, Tolerance Intervals, Exceedance, and Hypothesis Testing. Confidence intervals on mean. CL = x ± t * CL1- = exp

Week 14 Comparing k(> 2) Populations

Lecture 7: Hypothesis Testing and ANOVA

One-Way Analysis of Variance. With regression, we related two quantitative, typically continuous variables.

Business Statistics: Lecture 8: Introduction to Estimation & Hypothesis Testing

Statistical Inference: Estimation and Confidence Intervals Hypothesis Testing

Average weight of Eisenhower dollar: 23 grams

2.830J / 6.780J / ESD.63J Control of Manufacturing Processes (SMA 6303) Spring 2008

The problem of base rates

Descriptive Statistics. Population. Sample

Lecture on Null Hypothesis Testing & Temporal Correlation

COMPARING SEVERAL MEANS: ANOVA

BIOL Biometry LAB 6 - SINGLE FACTOR ANOVA and MULTIPLE COMPARISON PROCEDURES

z and t tests for the mean of a normal distribution Confidence intervals for the mean Binomial tests

Hypothesis for Means and Proportions

ANOVA: Comparing More Than Two Means

Lecture 8 Hypothesis Testing

CH.9 Tests of Hypotheses for a Single Sample

Hypothesis Testing. ) the hypothesis that suggests no change from previous experience

The Purpose of Hypothesis Testing

Design of Engineering Experiments Part 2 Basic Statistical Concepts Simple comparative experiments

16.400/453J Human Factors Engineering. Design of Experiments II

Contrasts and Multiple Comparisons Supplement for Pages

Power & Sample Size Calculation

Battery Life. Factory

Statistical Analysis for QBIC Genetics Adapted by Ellen G. Dow 2017

Chapter Seven: Multi-Sample Methods 1/52

Inference About Two Means: Independent Samples

Two Sample Problems. Two sample problems

Lecture Testing Hypotheses: The Neyman-Pearson Paradigm

Regression Part II. One- factor ANOVA Another dummy variable coding scheme Contrasts Mul?ple comparisons Interac?ons

Hypothesis testing I. - In particular, we are talking about statistical hypotheses. [get everyone s finger length!] n =

MTMS Mathematical Statistics

14.30 Introduction to Statistical Methods in Economics Spring 2009

Statistical Data Analysis Stat 3: p-values, parameter estimation

y ˆ i = ˆ " T u i ( i th fitted value or i th fit)

Medical statistics part I, autumn 2010: One sample test of hypothesis

Transcription:

Gene$cs 300: Sta$s$cal Analysis of Biological Data Lecture 3: Comparison of Means Two sample t test Analysis of variance Type I and Type II errors Power More R commands September 23, 2010 Two sample Test Previously, we compared a sample mean with a known value: : µ = µ 0 Now, we want to compare two unknown means: : µ 1 = µ 2 Are the data paired or unpaired? Two samples are paired if each data point in one sample is related to a unique data point in the other. Example: tes$ng each pa$ent before and aper interven$on Paired Data For paired data, this is really just a one sample test of the differences d i =X i2 X i1 with mean Δ. : µ 1 = µ 2 : Δ = 0 So the test sta$s$c t = d s d / where is the sample average of the differences and is the d sample s.d. of the differences, follows a t distribu$on with (n 1) degrees of freedom (d.o.f.) under n s d 1

Unpaired Two Sample Test Two versions, depending on whether the variances in the two popula$ons are equal or not Unequal variances Equal variances Unpaired Two Sample Test How to decide whether the variances are the same or not? Using unequal variances should be fine in most cases F test to test if the popula$ons have equal variances For two normal popula$ons with means µ 1 and µ 2 and a common variance σ 2, if you take two samples of size n 1 and n 2, follows an F distribu$on with (n 1 1,n 2 1) d.o.f. t follows a t distribu$on with some d.o.f. (the formula is complicated) t follows a t distribu$on with (n 1 +n 2 2) d.o.f. Example Is daily caloric consump$on equal in two popula$ons? We took two samples and found the following: Example Step 1: Test equality of variances qf(.975,12,9) Test the hypothesis that the mean consump$on is the same in both popula$ons. There is no evidence for different popula$on variances use equal variances method We reject the null hypothesis and conclude that the two popula$ons have different means. 2

Confidence Interval The 100(1 a)% confidence interval for the true mean differences Recall that we expected 95% of the data from a normal distribu$on to be contained in µ ±1.96σ Unequal variances So in the current example, the CI is Equal variances Other Methods for Two group Comparisons Many methods have been devised for this problem Signal to noise : X 1 X 2 s 1 + s 2 Where can the t test go wrong? With a small sample, s may be small by chance Regularize X 1 X 2 s 0 + s Ref: Significance analysis of microarrays, Tusher et al, PNAS 2001 What if we have more than two groups? Suppose we have k popula$ons, each roughly normal with common variance σ 2. How do we test for : µ 1 =µ 2 = =µ k? The extension of the t test to this case is known as one way Analysis of Variance The name is decep$ve: we need to analyze variances to test for a difference in means What is H A? That at least one of the popula@on means differs from one of the others Can we just test all possible pairs using the two sample t test? For 3 groups, we need 3 tests ( 3 choose 2 ) This becomes more complicated with more groups This is also likely to lead to an incorrect conclusion Suppose you have 3 groups and is true. Type I error: P(reject in at least 1) = 1 P(fail to reject in all 3) = 1 (1 0.05) 3 = 1 0.857 = 0.143 3

Bonferroni Correc$on We want to specify α, the probability of Type I error out of all comparisons. We can do this by using, for each individual test More group more stringent threshold Bonferroni correc@on simply divide the desired overall α by the number of tests This is conserva@ve. The level of the test is guaranteed to be less than or equal to α. Controlling Type I error is fine if you re worried about the possibility of a single false posi$ve. We will discuss false discovery rate later We have to assume that the underlying popula$on variances are iden$cal (σ 1 =σ 2 =...=σ) Variance consists of two components: the varia$on of the individual values around their popula$on means, and the varia$on of the popula$on means around the overall mean Is there more varia$on within groups or between groups? Compare the following scenarios: Does the variability in the data come mainly from the varia$on within groups, or is it mostly a result of the varia$on between groups? Some nota$ons: x ij is the jth observa$on in the ith group ith group has size n i Use sum of squares to measure variability 4

Sum of Squares Table We also define the following mean squares by dividing by the degrees of freedom We can now test for using We reject if F > F k 1,n k,1 α and conclude that at least one mean is different. To know which one is different, we must do ttests between groups Errors in hypothesis tes$ng Type I and Type II errors Sta$s$cal Power : µ = µ 0 : µ = µ 1 Consider vs is true H 1 is true Reject Type I error correct Not reject correct Type II error P(Type I error) = P(reject is true) = α false alarm P(Type II error) = P(not reject H 1 is true) = β alarm failure Power = P(reject H 1 is true) = 1 β We want our test to be powerful so that we can detect a different if it exists. Figure from HST 190 notes (Betensky) 5

Power Trade off between Type I and Type II errors Lower Type I error rate higher Type II error rate & loss of power How do we compute power? (for one sided test) Φ(c) = P(Z c) (area to the lep of c for Z~N(0,1)) What are the factors affec$ng power? n, σ, α, µ 1 µ 0 Example Researchers wish to test whether a drug is effec$ve in reducing intraocular pressure by 5mm Hg (for glaucoma preven$on). They will conclude effec$veness if they see a result significant at the 5% level. The std. dev. of the pressure change, on the basis of previous experiments, is believed to be 20. If they administer the drug to 100 pa$ents, what is the probability they will detect a change if the drug is truly effec@ve? n=100, σ=20, α=0.05, µ 1 µ 0 =5 Sample size Instead of fixing n and calcula$ng power, we can select desired level of power and calculate n. For a two sided test, subs$tute for z 1 α / 2 z 1 α for all these formulas 6