Elementary statistics

Slides:



Advertisements
Similar presentations
Elementary statistics Michael Ernst CSE 190p University of Washington.
Advertisements

Last Time (Sampling &) Estimation Confidence Intervals Started Hypothesis Testing.
Chapter 10 Section 2 Hypothesis Tests for a Population Mean
Hypothesis Testing. Coke vs. Pepsi Hypothesis: tweets reflect market share (people tweet as much as they drink) Market share: – 67% vs. 33% From tweets:
Section 7.1 Hypothesis Testing: Hypothesis: Null Hypothesis (H 0 ): Alternative Hypothesis (H 1 ): a statistical analysis used to decide which of two competing.
Elementary statistics Ruth Anderson CSE 140 University of Washington 1.
Warm-up Day of 8.1 and 8.2 Quiz and Types of Errors Notes.
1 © Lecture note 3 Hypothesis Testing MAKE HYPOTHESIS ©
© 2008 McGraw-Hill Higher Education The Statistical Imagination Chapter 9. Hypothesis Testing I: The Six Steps of Statistical Inference.
Testing Hypotheses Tuesday, October 28. Objectives: Understand the logic of hypothesis testing and following related concepts Sidedness of a test (left-,
Chapter 8 Hypothesis Testing I. Chapter Outline  An Overview of Hypothesis Testing  The Five-Step Model for Hypothesis Testing  One-Tailed and Two-Tailed.
Hypothesis Testing: One Sample Cases. Outline: – The logic of hypothesis testing – The Five-Step Model – Hypothesis testing for single sample means (z.
Chapter 10 Hypothesis Testing
Introduction to Data Analysis. Hypothesis Testing for means and proportions.
Chapter 3 Investigating Independence Objectives Students will be able to: 1) Understand what it means for attempts to be independent 2) Determine when.
1 If we live with a deep sense of gratitude, our life will be greatly embellished.
Warm-up Day of 8.1 and 8.2 Review. 8.2 P#20, 23 and 24 P#20 a. and b. c. Since the p-hat is along the line for reasonably likely events.
Introduction to Statistics for the Social Sciences SBS200, COMM200, GEOG200, PA200, POL200, or SOC200 Lecture Section 001, Spring 2015 Room 150 Harvill.
Economics 173 Business Statistics Lecture 4 Fall, 2001 Professor J. Petry
CHAPTER 9 Testing a Claim
Rejecting Chance – Testing Hypotheses in Research Thought Questions 1. Want to test a claim about the proportion of a population who have a certain trait.
Chapter 8 Hypothesis Testing I. Significant Differences  Hypothesis testing is designed to detect significant differences: differences that did not occur.
Welcome to MM570 Psychological Statistics
Lecturer’s desk INTEGRATED LEARNING CENTER ILC 120 Screen Row A Row B Row C Row D Row E Row F Row G Row.
Statistical Inference Making decisions regarding the population base on a sample.
Introduction to Probability – Experimental Probability.
Introduction to Statistics for the Social Sciences SBS200, COMM200, GEOG200, PA200, POL200, or SOC200 Lecture Section 001, Fall 2015 Room 150 Harvill.
Introduction to Statistics for the Social Sciences SBS200, COMM200, GEOG200, PA200, POL200, or SOC200 Lecture Section 001, Fall 2015 Room 150 Harvill.
Elementary statistics Ruth Anderson CSE 160 University of Washington 1.
The Practice of Statistics, 5th Edition Starnes, Tabor, Yates, Moore Bedford Freeman Worth Publishers CHAPTER 9 Testing a Claim 9.1 Significance Tests:
Hypothesis Testing. A statistical Test is defined by 1.Choosing a statistic (called the test statistic) 2.Dividing the range of possible values for the.
Statistical principles: the normal distribution and methods of testing Or, “Explaining the arrangement of things”
Modern Languages Row A Row B Row C Row D Row E Row F Row G Row H Row J Row K Row L Row M
Copyright © 2010 Pearson Education, Inc. Publishing as Prentice Hall Statistics for Business and Economics 7 th Edition Chapter 9 Hypothesis Testing: Single.
Lecture #8 Thursday, September 15, 2016 Textbook: Section 4.4
Introduction to Hypothesis Testing: The Binomial Test
Section Testing a Proportion
Hypothesis Testing.
One-Sample Inference for Proportions
FINAL EXAMINATION STUDY MATERIAL III
Business Statistics Topic 7
Review You run a t-test and get a result of t = 0.5. What is your conclusion? Reject the null hypothesis because t is bigger than expected by chance Reject.
A Closer Look at Testing
Introduction to Hypothesis Testing: The Binomial Test
CHAPTER 9 Testing a Claim
Introduction to Statistics for the Social Sciences SBS200 - Lecture Section 001, Spring 2017 Room 150 Harvill Building 9:00 - 9:50 Mondays, Wednesdays.
Introduction to Statistics for the Social Sciences SBS200 - Lecture Section 001, Fall 2016 Room 150 Harvill Building 10: :50 Mondays, Wednesdays.
Consider This… I claim that I make 80% of my basketball free throws. To test my claim, you ask me to shoot 20 free throws. I make only 8 out of 20.
Inferential Statistics
Introduction to Statistics for the Social Sciences SBS200 - Lecture Section 001, Spring 2018 Room 150 Harvill Building 9:00 - 9:50 Mondays, Wednesdays.
When we free ourselves of desire,
INTEGRATED LEARNING CENTER
Elementary statistics
Elementary statistics
Making Data-Based Decisions
Introduction to Statistics for the Social Sciences SBS200, COMM200, GEOG200, PA200, POL200, or SOC200 Lecture Section 001, Spring 2016 Room 150 Harvill.
Testing Hypotheses about Proportions
CHAPTER 9 Testing a Claim
Hypothesis Testing and Comparing Two Proportions
CHAPTER 9 Testing a Claim
Tuesday: CLT; hypothesis testing; and Type I vs II
Chapter 3 Probability Sampling Theory Hypothesis Testing.
The Language of Statistical Decision Making
Statistics 300: Elementary Statistics
Hypothesis Testing.
Hypothesis Testing and Confidence Intervals (Part 2): Cohen’s d, Logic of Testing, and Confidence Intervals Lecture 9 Justin Kern April 9, 2018.
CHAPTER 9 Testing a Claim
Chapter 9: Testing a Claim
CHAPTER 9 Testing a Claim
CHAPTER 9 Testing a Claim
Presentation transcript:

Elementary statistics UW CSE 160

A dice-rolling game Two players each roll a die The higher roll wins Goal: roll as high as you can! Repeat the game 6 times Have one student roll the die, and the other report the outcome

Hypotheses regarding the outcome Luck Fraud loaded die inaccurate reporting How likely is luck? How do we decide?

Questions that statistics can answer I am flipping a coin. Is it fair? How confident am I in my answer? I have two bags of beans, each containing some black and some white beans. I have a handful of beans. Which bag did the handful come from? I have a handful of beans, and a single bag. Did the handful come from that bag? Does this drug improve patient outcomes? Which website design yields greater revenue? Which baseball player should my team draft? What premium should an insurer charge? Which chemical process leads to the best-tasting beer? “Student” was William Gosset, a chemist working for the Guinness brewery in Dublin

What can happen when you roll a die? What is the likelihood of each?

What can happen when you roll two dice? How likely are you to roll 11 or higher? This probability is known as the “p value”. 2 3 4 5 6 7 8 9 10 11 12

How to compute p values Via a statistical formula Requires you to make assumptions and know which formula to use Computationally (simulation) Run many experiments Count the fraction with a better result Requires a metric/measurement for “better” Requires you to be able to run the experiments We will use this approach exclusively

Analogy between hypothesis testing and mathematical proofs “The underlying logic [of hypothesis testing] is similar to a proof by contradiction. To prove a mathematical statement, A, you assume temporarily that A is false. If that assumption leads to a contradiction, you conclude that A must actually be true.” From the book Think Statistics by Allen Downey

Summary of statistical methodology Decide on a metric (bigger value = better) Observe what you see in the real world Hypothesize that what you saw is normal/typical This is the “null hypothesis” Simulate the real world many times How different is what you observed from the simulations? What percent of the simulation values are the real world values bigger than? If the percentage is 95% or more, reject the null hypothesis

Null Hypothesis Null Hypothesis: The common wisdom, “nothing unusual is happening here” Examples: Ruth was using a fair die The accused is innocent This new drug does NOT cure disease The Iranian election results are accurate

Interpreting p values p value of 5% or less = statistically significant This is a convention; there is nothing magical about 5% Two types of errors may occur in statistical tests: false positive (or false alarm or Type I error): no real effect, but report an effect (through good/bad luck or coincidence) If no real effect, a false positive occurs about 1 time in 20 false negative (or miss or Type II error): real effect, but report no effect (through good/bad luck or coincidence) The larger the sample, the less the likelihood of a false positive or negative

Errors Type 1: False Positive (false alarm) Type 2: False negative (miss) Examples: Ruth was using a fair die Type 1: Die is actually fair, falsely accused of cheating! Type 2: Die is actually biased, you don’t notice The accused is innocent This new drug does NOT cure disease The Iranian election results are accurate

Error Examples Type 1: False Positive (false alarm) Type 2: False negative (miss) Examples: Ruth was using a fair die Type 1: Die is actually fair, falsely accused of cheating! Type 2: Die is actually biased, you don’t notice The accused is innocent Type 1: Type 2: This new drug does NOT cure disease The Iranian election results are fair/accurate

Answer: Error Examples Type 1: False Positive (false alarm) Type 2: False negative (miss) Examples: Ruth was using a fair die Type 1: Die is actually fair, accuse me of lying! Type 2: Die is actually biased, you don’t notice The accused is innocent Type 1: Actually innocent, court finds guilty Type 2: Actually guilty, court sets them free This new drug does NOT cure disease Type 1: Drug actually does nothing, study claims it does Type 2: Drug actually does help, study claims it does not The Iranian election results are fair/accurate Type 1: Results are actually fair, we claim they are fraudulent Type 2: Results are actually fraudulent, we claim they are fair

A false positive http://xkcd.com/882/

http://xkcd.com/882/ http://xkcd.com/882/

A common error Observe what you see in the real world Decide on a metric (bigger value = better) This is backwards For any observation, there is something unique about it. Example: Roll dice, then be amazed because what are the odds you would get exactly that combination of rolls?

Correlation  causation Ice cream sales and rate of drowning deaths are correlated http://xkcd.com/552/

Statistical significance  practical importance

Don’t trust your intuition People have very bad statistical intuition It’s much better to follow the methodology and do the experiments