Hypothesis Testing. The idea of hypothesis testing is:

Similar documents
Introduction to Hypothesis Testing. Hypothesis Testing. Step 1: State the Hypotheses

Testing a claim about a population mean

Section 7.1. Introduction to Hypothesis Testing. Schrodinger s cat quantum mechanics thought experiment (1935)

Chapter 7 Notes - Inference for Single Samples. You know already for a large sample, you can invoke the CLT so:

Mind on Statistics. Chapter 12

MULTIPLE CHOICE. Choose the one alternative that best completes the statement or answers the question.

C. The null hypothesis is not rejected when the alternative hypothesis is true. A. population parameters.

Calculating P-Values. Parkland College. Isela Guerra Parkland College. Recommended Citation

Stat 411/511 THE RANDOMIZATION TEST. Charlotte Wickham. stat511.cwick.co.nz. Oct

BA 275 Review Problems - Week 5 (10/23/06-10/27/06) CD Lessons: 48, 49, 50, 51, 52 Textbook: pp

Unit 31 A Hypothesis Test about Correlation and Slope in a Simple Linear Regression

Online 12 - Sections 9.1 and 9.2-Doug Ensley

Lesson 1: Comparison of Population Means Part c: Comparison of Two- Means

Class 19: Two Way Tables, Conditional Distributions, Chi-Square (Text: Sections 2.5; 9.1)

HYPOTHESIS TESTING WITH SPSS:

Two-Sample T-Tests Assuming Equal Variance (Enter Means)

Testing Hypotheses About Proportions

HYPOTHESIS TESTING: POWER OF THE TEST

BA 275 Review Problems - Week 6 (10/30/06-11/3/06) CD Lessons: 53, 54, 55, 56 Textbook: pp , ,

THE FIRST SET OF EXAMPLES USE SUMMARY DATA... EXAMPLE 7.2, PAGE 227 DESCRIBES A PROBLEM AND A HYPOTHESIS TEST IS PERFORMED IN EXAMPLE 7.

AP STATISTICS (Warm-Up Exercises)

Non-Parametric Tests (I)

In the general population of 0 to 4-year-olds, the annual incidence of asthma is 1.4%

Stats Review Chapters 9-10

Chapter 8 Hypothesis Testing Chapter 8 Hypothesis Testing 8-1 Overview 8-2 Basics of Hypothesis Testing

How To Test For Significance On A Data Set

Comparing Two Groups. Standard Error of ȳ 1 ȳ 2. Setting. Two Independent Samples

Two-Sample T-Tests Allowing Unequal Variance (Enter Difference)

Hypothesis Testing: Two Means, Paired Data, Two Proportions

6: Introduction to Hypothesis Testing

1-3 id id no. of respondents respon 1 responsible for maintenance? 1 = no, 2 = yes, 9 = blank

CHAPTER 14 NONPARAMETRIC TESTS

Practice problems for Homework 12 - confidence intervals and hypothesis testing. Open the Homework Assignment 12 and solve the problems.

Introduction to Hypothesis Testing OPRE 6301

Hypothesis Testing. Steps for a hypothesis test:

Hypothesis Test for Mean Using Given Data (Standard Deviation Known-z-test)

3.4 Statistical inference for 2 populations based on two samples

A) B) C) D)

Hypothesis testing. c 2014, Jeffrey S. Simonoff 1

Hypothesis testing - Steps

Name: Date: Use the following to answer questions 3-4:

One-sample test of proportions

Using Stata for One Sample Tests

Introduction. Hypothesis Testing. Hypothesis Testing. Significance Testing

Permutation & Non-Parametric Tests

LAB 4 INSTRUCTIONS CONFIDENCE INTERVALS AND HYPOTHESIS TESTING

Week 3&4: Z tables and the Sampling Distribution of X

Hypothesis Testing. Reminder of Inferential Statistics. Hypothesis Testing: Introduction

Introduction to Hypothesis Testing

STAT 350 Practice Final Exam Solution (Spring 2015)

Chapter 4: Statistical Hypothesis Testing

z-scores AND THE NORMAL CURVE MODEL

Comparing Multiple Proportions, Test of Independence and Goodness of Fit

SAMPLING & INFERENTIAL STATISTICS. Sampling is necessary to make inferences about a population.

Nonparametric tests these test hypotheses that are not statements about population parameters (e.g.,

Odds ratio, Odds ratio test for independence, chi-squared statistic.

Unit 26 Estimation with Confidence Intervals

Chapter 8: Hypothesis Testing for One Population Mean, Variance, and Proportion

Permutation Tests for Comparing Two Populations

The power of a test is the of. by using a particular and a. value of the that is an to the value

Name: (b) Find the minimum sample size you should use in order for your estimate to be within 0.03 of p when the confidence level is 95%.

General Method: Difference of Means. 3. Calculate df: either Welch-Satterthwaite formula or simpler df = min(n 1, n 2 ) 1.

MATH 140 HYBRID INTRODUCTORY STATISTICS COURSE SYLLABUS

Normal Distribution Example 1

Statistiek I. Proportions aka Sign Tests. John Nerbonne. CLCG, Rijksuniversiteit Groningen.

Non-Inferiority Tests for Two Means using Differences

Interim Analysis in Clinical Trials

WISE Power Tutorial All Exercises

Biostatistics: Types of Data Analysis

HYPOTHESIS TESTING (ONE SAMPLE) - CHAPTER 7 1. used confidence intervals to answer questions such as...

MONT 107N Understanding Randomness Solutions For Final Examination May 11, 2010

Understand the role that hypothesis testing plays in an improvement project. Know how to perform a two sample hypothesis test.

NCSS Statistical Software

Hypothesis Testing --- One Mean

Introduction. Statistics Toolbox

22. HYPOTHESIS TESTING

How to get accurate sample size and power with nquery Advisor R

NCSS Statistical Software. One-Sample T-Test

Tests for Two Proportions

Chicago Booth BUSINESS STATISTICS Final Exam Fall 2011

Section 13, Part 1 ANOVA. Analysis Of Variance

HYPOTHESIS TESTING (ONE SAMPLE) - CHAPTER 7 1. used confidence intervals to answer questions such as...

Experimental Design. Power and Sample Size Determination. Proportions. Proportions. Confidence Interval for p. The Binomial Test

Descriptive Statistics

1 Hypothesis Testing. H 0 : population parameter = hypothesized value:

The Wilcoxon Rank-Sum Test

Appendix A: Deming s 14 Points for Management

Comparison of frequentist and Bayesian inference. Class 20, 18.05, Spring 2014 Jeremy Orloff and Jonathan Bloom

Math 58. Rumbos Fall Solutions to Assignment #3

LAB : THE CHI-SQUARE TEST. Probability, Random Chance, and Genetics

Statistics 100 Sample Final Questions (Note: These are mostly multiple choice, for extra practice. Your Final Exam will NOT have any multiple choice!

How to evaluate medications in Multiple Sclerosis when placebo controlled RCTs are not feasible

Business Statistics, 9e (Groebner/Shannon/Fry) Chapter 9 Introduction to Hypothesis Testing

Chapter Study Guide. Chapter 11 Confidence Intervals and Hypothesis Testing for Means

Chapter 26: Tests of Significance

Principles of Hypothesis Testing for Public Health

Hypothesis Testing for Beginners

Study Guide for the Final Exam

Transcription:

Hypothesis Testing The idea of hypothesis testing is: Ask a question with two possible answers Design a test, or calculation of data Base the decision (answer) on the test Example: In 2010, 24% of children were dressed as Justin Bieber for Halloween. We want to test whether or not this proportion increased in 2011.

Constructing a Hypothesis Test Define your Null and Alternative Hypotheses H 0 (pronounced H naught ) is the null hypothesis. This is typically the default assumption assuming no change, or that a new drug is no better than a placebo. H A is the alternative hypothesis. This is typically your hunch, that there has been a change, or that the drug works better than the placebo, or a claim that you are trying to debunk.

Example: Justin Bieber Costumes H 0 : In 2011, 24% of Halloween costumes were Bieber costumes. (p=.24) H A : In 2011, the proportion of Bieber costumes was greater than 24%; (p>.24)

Alternative Hypothesis The Alternative Hypothesis is chosen to match a claim that is being tested, or something you hope is true. Say we are testing for a proportion p. Null Hypothesis is p=p 0. If the Alternative Hypothesis is p>p 0, or if it is p<p 0, these are examples of a one-sided test. If the alternative is p p 0, this is called a twosided test.

Calculate a Test Statistic For a hypothesis test about population proportion, sample proportion is a good test statistic (if the conditions of the CLT are met, we can use the normal distribution) Example: We randomly poll 1000 children who dressed up for Halloween in 2011. 254 of them dressed up as Justin Bieber, so our sample proportion is.254

P-Value For a hypothesis test of a proportion, we use a P- Value. This is the conditional probability of the tails assuming H 0 is true. The smaller the P-value, the more strong the evidence in favor of our alternative Hypothesis. If the P-Value is less than or equal to a certain predefined threshold (the significance level), we will reject the null Hypothesis.

Calculating P-Values (1-sided tests) p ^ is normal with μ=p 0, σ= (p 0 (1-p 0 )/n) Calculate x/n, the proportion from our observed sample. Case1: H 0 : p=p 0 vs. H A : p>p 0 P-Value= P[p>x/n ^ p=p 0 ] =normalcdf(x/n,1,μ,σ) Case2: H 0 : p=p 0 vs. H A : p<p 0 P-Value= P[p<x/n ^ p=p 0 ] =normalcdf(0,x/n,μ,σ)

Example: Calculate P-Value We are using a 5% significance level. If we assume H 0 true, then p, our sample proportion, is normal with μ=.24 and σ= (.24*.76/1000)=.0135 ^ P[p>.254 H 0 ] =normalcdf(.254,1,.24,.0134) =.1481 This is not less than our.05 significance level, so we do not reject the null hypothesis The evidence is not strong enough to support the claim that Justin Bieber costumes were more popular in 2011 than in 2010. ^

Visual Hypothesis Test H 0 : p=p 0 vs. H A : p>p 0 5% significance level By CLT, p ^ is normal with μ=p 0, σ= (p 0 q 0 /n) (Assuming H 0 is true) Calculate x/n, our observed sample proportion Distribution of p^ 95% 5% p 0 If x/n is here, do not reject H 0 If x/n is here, we WILL reject H 0

Visual Hypothesis Test H 0 : p=p 0 vs. H A : p<p 0 5% significance level By CLT, p ^ is normal with μ=p 0, σ= (p 0 q 0 /n) (Assuming H 0 is true) Calculate x/n, our observed sample proportion Distribution of p^ 95% 5% p 0 If x/n is here, we WILL reject H 0 If x/n is here, do not reject H 0

2-Sided Test A Two tailed test looks like this: H 0 : p=p 0 vs. H A :p p 0, 5% significance level Distribution of ^ p (Assuming H0 is true) 2.5% 95% 2.5% p 0 If x/n is here, we WILL reject H 0 If x/n is here, do not reject H 0 If x/n is here, we WILL reject H 0

Calculating P-Values (2-sided tests) p ^ is normal with μ=p 0, σ= (p 0 q 0 /n) Calculate x/n, the proportion from our observed sample. H 0 : p=p 0 vs. H A :p p 0 use standardized z value z= x n μ P-Value= 2P[Z> z p=p ^ 0 ] =2*normalcdf( z,6) Notice we use z - the absolute value of z σ = x n p 0 p 0q 0 n

Example- 2-sided test In 1996, 25% of students who had perfect attendance one month would also have perfect attendance the following month. In 2000, the school wants to see if the proportion has changed. The proportion of a random sample of 6543 students is 23.4%. With a 5% significance level, should the school conclude that there has been a change? H 0 : proportion is still 25%, H A : proportion is not 25% Under the null hypothesis, p ^ is normal with mean 0.25 and s.d (.25*.75/6453)=.00535 Standardized proportion is z=(.234-.25)/.00535 =-2.9907 P value is 2*P[Z>2.9907] = 2*normalcdf(2.9907,6)=.0028 This is less than.05, so we reject the null hypothesis; there has been a change in attendance.

Test using Z-Statistic You can calculate the P-Value using a z-score: Assume null hypothesis: μ=p 0, σ= (p 0 q 0 /n) X/n is our sample proportion. z=(x-μ)/σ The P-value depends on the form of H A : H A :p>p 0 P-Value = P(Z>z)=normalcdf(z,6) H A :p<p 0 P-Value = P(Z<z)=normalcdf(-6,z) H A :p p 0 P-Value = 2P(Z> z )=2*normalcdf( z,6) Remember, for 2-tailed test use z (absolute value)

One-Sided Test using Z-statistic A Magazine wants to launch an online version, but only if more than 20% of its subscribers would subscribe to it. A random survey of 400 subscribers indicated that 90 would be interested. H 0 : p=20%, H A : p>20%, assume 5% significance level Sample proportion is 90/400=.225 Under the null hypothesis, p ^ is normal with mean 0.20 and s.d (.20*.80/400)=.02 Standardized proportion is z=(.225-.20)/.02 =1.25 P value is P[Z>1.25] = normalcdf(1.25,6)=.10565 This is higher than our.05 significance level; evidence is not strong enough to reject the null hypothesis. The magazine should not launch the online version.