One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf ·...
Transcript of One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf ·...
![Page 1: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/1.jpg)
One more example of a hypothesis test
Chapter 10: Scatterplots
If time: Joy of Stats – 200 Countries, 200 Years
![Page 2: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/2.jpg)
You should know this.
![Page 3: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/3.jpg)
You should be familiar with all of this, but don’t waste
too much time memorizing.
![Page 4: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/4.jpg)
Alzhiemer’s Onset and Gender (From Ch.7 exercises, #21)
We’ve been given a list of age of Alzheimer’s onset ages from
men and women.
We want to find out if there is a difference between the ages
that men get Alzheimer’s and the age women get it.
Alzheimer’s Onset Men Women Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size 8 9
![Page 5: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/5.jpg)
Is this a one-sided or two-sided test?
“If there’s a difference” tells us this is…
______________
![Page 6: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/6.jpg)
It’s a two-sided test…
Is it about means or proportions?
We’re talking about ages, so the ___________ is
appropriate.
![Page 7: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/7.jpg)
It’s a two-sided test of a mean or means.
We weren’t told otherwise, so we don’t know the true
standard deviation.
We use the sample standard deviation instead.
![Page 8: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/8.jpg)
It’s a two-sided test of a mean or means, using the sample
standard deviation
We’re comparing men and women, so we’re
interested in ________________
![Page 9: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/9.jpg)
It’s a two-sided, two-sample test of means, using the sample
standard deviation
Is it an independent or a paired test?
There a different number of people in each
group, so they must be ________________
![Page 10: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/10.jpg)
Hope you’re not getting caught up in the concepts
![Page 11: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/11.jpg)
We have this data:
Alzheimer’s Onset Men Women Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size 8 9
And we know to do an independent two-sample test.
All our formulae will have t and s in them, instead of z
and sigma.
If we do a confidence interval, it will have mu =
something, instead of pi = something.
![Page 12: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/12.jpg)
We input the raw data into SPSS and then click
Analyze Compare Means Independent T Test
We get this for the first couple columns:
![Page 13: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/13.jpg)
From this result we _____________ assume equal
variances. This is because __________________,
so we use the __________ row.
![Page 14: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/14.jpg)
We get this for the middle five columns of the table.
Sig. (2-tailed) is large so we _________________ the null.
That means we detect __________________ between the
onset age of alzhiemers between men and women.
![Page 15: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/15.jpg)
We can also tell that the difference between the means was
________ standard errors. (t-score)
The area beyond this score (on both sides) was found on the t-
distribution with _____ degrees of freedom.
The area was ____________ (p-value)
![Page 16: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/16.jpg)
To a new chapter we go!
![Page 17: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/17.jpg)
Chapter 10: Correlations
Correlations are one way to quanity and show the
relationship between two features of the same object.
Usually this is between two sets interval data,
otherwise it’s called an association.
![Page 18: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/18.jpg)
If two values increase together, they are said to be
positively correlated. (As one goes up, so does the
other)
If one value increases as the other decreases, they are
said to be negatively correlated.
![Page 19: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/19.jpg)
Example: Longer bearded dragons tend to be larger all
around, so they weigh more.
Length and Weight are positively correlated in bearded
dragons.
Example: Heating bills tend to be a lot less when it’s
warmer out.
Heating Cost and Outdoor Temperature are
negatively correlated.
![Page 20: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/20.jpg)
The most common graph to show two sets of interval
data together is the scatter plot.
![Page 21: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/21.jpg)
Each dot represents a subject. In Length vs. Weight,
each dot is a dragon.
![Page 22: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/22.jpg)
The height of the dot represents the length of the
dragon. How far it is to the right represents the weight
of the dragon.
The dragon for this dot is 18cm long, and weighs 700g.
![Page 23: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/23.jpg)
There is an obvious upward trend in the graph. This
shows a positive correlation.
![Page 24: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/24.jpg)
The negative correlation between heating cost and
outdoor temperature can be shown the same way.
![Page 25: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/25.jpg)
The lack of correlation between two variables can also
be show in a scatterplot.
![Page 26: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/26.jpg)
The strength of a correlation is how well the data
points fit onto a straight line .
Stronger correlations are easier to see and have less
random scatter or variation.
![Page 27: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/27.jpg)
We can quantify the strength and direction of a
correlation with the correlation coefficient.
The correlation coefficient, called…
r from a sample and (we’ll see r frequently)
ρ, or rho from a population. (we’ll see rho rarely)
Is a value between -1 and 1 that tells how strong a correlation
is and in what direction.
![Page 28: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/28.jpg)
The stronger a correlation, the farther the coefficient is from
zero (and the closer it is to 1 or -1)
Positive correlations have positive coefficients r.
Negative correlations have negative coefficients r.
![Page 29: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/29.jpg)
The stronger the negative correlation, the closer it is to -1.
![Page 30: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/30.jpg)
A perfect correlation, one in which all the values fit perfectly
on a line, has a correlation 1 (for positive) or -1 (for negative).
![Page 31: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/31.jpg)
If there is no correlation at all, r will have a value of zero.
However, since r is from a sample, it will vary like everything
else from a sample. Instead of zero, it usually has some value
close to zero on either side.
![Page 32: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/32.jpg)
Recall the Burnaby vs. Coquitlam gas example from last week.
One reason a pooled t-test was appropriate was because gas
prices between the two cities were correlated.
![Page 33: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/33.jpg)
Guess the correlation coefficient between Burnaby and
Coquitlam gas prices.
A) r = 0.05 B) r = 0.97
C) r = 0.592 D) r = -0.592
![Page 34: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/34.jpg)
There is a relationship between Burnaby and Coquitlam gas
prices, but it’s not a perfect relationship.
It’s postive, so the correlation coefficient r is postive, not
negative.
![Page 35: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/35.jpg)
Which of these is a possible correlation coefficent?
A) r = -0.28
B) r = 1.21
C) r = 0.41 grams per bean.
![Page 36: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/36.jpg)
Which of these is a possible correlation coefficent?
r is always between -1 and 1. Also, it has no units, so ‘grams
per bean’ doesn’t make much sense, even through it’s a
relationship between two variables.
![Page 37: One more example of a hypothesis test Chapter 10: Scatterplots …jackd/Stat203_2011/Wk08_1.pdf · 2012. 7. 4. · Sample Mean 67.75 66.55 Standard Devation 6.58 5.34 Sample Size](https://reader035.fdocuments.us/reader035/viewer/2022071515/61370dae0ad5d20676485f0c/html5/thumbnails/37.jpg)
Joy of Stats 28:45 – 33:00 (200 Countries, 200 Years)
Next time: r-squared,significance test for correlation.
nonlinearity.