Download 17. Inferential Statistics

Document related concepts

Bootstrapping (statistics) wikipedia , lookup

Inductive probability wikipedia , lookup

Taylor's law wikipedia , lookup

History of statistics wikipedia , lookup

Foundations of statistics wikipedia , lookup

Student's t-test wikipedia , lookup

Resampling (statistics) wikipedia , lookup

Misuse of statistics wikipedia , lookup

Transcript
 Probability
 Sampling
Agenda
error
 Hypothesis Testing
 Significance level
Tossing a Coin
If you toss a fair coin, what are the
chances to get a head?
Probability
Probability (p)=
Frequency of occurrence (# getting Heads)
Number of trials (# of tosses)
Likelihood of getting Heads is 1 in 2
Probability of getting Heads= .5
Probability
Probability (p) ranges between 1 and 0
 p = 1 means that the event would occur in
every trial
 p = 0 means the event would never occur in
any trial
 The closer the probability is to 1, the more
likely that the event will occur
 The closer the probability is to 0, the less
likely the event will occur

Probability
Probability (p)
%
Every time
1
100%
Half the time
.5
50%
1 in 10
.1
10%
5 in 100
.05
5%
1 in 100
.01
1%
Tossing a Coin
If a large number of people toss a fair coin 10
times, we will get a bell-shape distribution with
the mean of 5.
0
5
# of times getting heads
10
Tossing a Coin
Normal Distribution (Bell-Curve)
 Symmetrical
 Largest # of cases at the mean
 Few extreme cases
0
5
# of times getting heads
10
Simple Classical Probability
Probability of getting a particular outcome
(e.g. Head of a coin) when each outcome
has an equal chance to occur
 Probability in a whole group
 “Probability” usually refers to simple
classical probability

Conditional Probability
Conditional probability refers to the
probability of one event given that another
event has occurred.
 If knowledge of one event helps to predict
the outcome of another event, these two
events are dependent
 If knowledge of one event does not help to
predict the outcome of another event, these
two events are independent

Probability of purchasing a Gucci bag
 Only 5 in 100 shoppers actually buy a bag
 Probability (p)= .05

Example: Conditional Probability
Event 1: Purchase
of a Gucci bag
Event 2: Possession
of Ferragamo shoes
Example: Conditional Probability



Of shoppers who have
Ferragamo shoes, 20
in 100 buy a bag
Conditional
probability = .2

Of shoppers who do
not have Ferragamo
shoes, 1 in 100 buy a
bag
Conditional
probability = .01
Conditional Probability
Own
Not Own
Buy
20%
1%
Not Buy
80%
99%
Example: Heights
Sample
 Draw groups of 100
students
 If your selection is
random, what is the
expected mean height
of the group?
Population
All students at School
 Mean height = 5.8 ft.

Example: Heights
5.8
5.7 5.8 5.9
5.6 5.7 5.8 5.9
5.5 5.6 5.7 5.8 5.9
5.4 5.5 5.6 5.7 5.8 5.9
5.4 5.5 5.6 5.7 5.8 5.9
5.4 5.5 5.6 5.7 5.8 5.9
5.4 5.5 5.6 5.7 5.8 5.9
5.4 5.5 5.6 5.7 5.8 5.9
6.0
6.0 6.1
6.0 6.1
6.0 6.1
6.0 6.1
6.0 6.1
6.0 6.1
5.8
= Expected Value
Sample mean
Example: Height at two Schools

Draw a sample from School A and School B
A
=?
Sample Sample
A
B
B
=?
 Measure heights of students in a sample from
each school
Example: Height at two Schools

Mean height of Sample A is 5.9 and Mean
height of Sample B is 5.7
A
=?
Sample Sample
A
B
5.7
5.9
B
=?
 Chances of getting the mean of 5.7 and the
mean of 5.9 from the same type of population
are high
Example: Height at two Schools
Mean 5.7
Mean 5.9
5.8
What if…

Mean height of Sample A is 5.2 and Mean
height of Sample B is 6.1
A
=?
Sample Sample
A
B
5.2
6.1
B
=?
 Chances of getting the mean of 5.2 and the
mean of 6.1 are low
Example: Height at two Schools
Mean 6.1
Mean 5.2
5.8
Example: Height at two Schools
Mean 5.2
School A 
Mean 6.1
School B 
P > .05 means that …
 Means of two groups fall in 95% central area of
normal distribution with one population mean
Mean 1
Mean 2
95%
P < .05 means that …
 Means of two groups do NOT fall in 95% central
area of normal distribution of one population
mean, so it is more reasonable to assume that
they belong to different populations
1
2
SIMPLE RANDOM SAMPLE
Population of 40:
25%
25%
50%
Sample of 4 :
Each person 1/10 chance
Sample A
Sample B
Sample D
Sample C
Random sampling error
Random sampling error:
Difference between sample
characteristics and population
characteristics
caused by chance
 Sampling bias:
Difference between sample characteristics and
population characteristics
caused by biased (non-random) sampling
SYSTEMATIC SAMPLE
Population of 40:
25%
25%
50%
For a sample of 4,
Take every 10th one
Sample B
Sample A
67% orange
33% white
83% orange
17% white
67% orange
33% white
Population
Sample
Statistics
X SD n
In fer
Population
Parameters

s
N
1. Infer characteristics of a
population from the
characteristics of the samples.
2. Hypothesis Testing
3. Statistical Significance
4. The Decision Matrix
Inferential Statistics

assess -- are the sample statistics
indicators of the population parameters?

Differences between 2 groups -- happened
by chance?

What effect do random sampling errors
have on our results?
Null Hypothesis
• Says IV has no influence on DV
• There is no difference between the two
variables.
• There is no relationship between the
two variables.
Logic of Inferential Statistics

You are cautious !

Default assumption = null hypothesis (no
difference)

Assume any differences in your data are
due to chance variation (sampling error)

What are the chances I would get these
results if null hypothesis is true?

Only if pattern is highly unlikely (p 
.05) do you reject null hypothesis
True state
Your decision:

There is nothing happening
except chance variation
(accept the null)
Data indicates something
significant is happening
(reject null)
Data results Data indicates
are by
something is
chance (Null happening (Null
is true)
is false)
Correct
Type II error
Type I
error
Correct
Null Hypothesis
States there is NO true difference between
the groups
 If sample statistics show any difference, it is
due to random sampling error
 Referred as H0
 (Research Hypothesis = Ha)
 If you can reject H0, you can support Ha
 If you fail to reject H0, you reject Ha

Two Possible Errors
IN FACT …
YOU…
H0 is true
H0 is false
Reject H0
Type I Error
Correct
Fail to reject
H0
Correct
Type II
Error
No fire
Correct
No Alarm
Alarm
Type I
error
Fire
Type II
error
Correct
True State
Ho (no fire)
Accept Ho
Correct
(no fire)
Reject Ho
(alarm)
Type I
error
Ha
(fire)
Type II
error
Correct
Ho = null hypothesis =
there is NO fire
Ha = alternative hyp. =
there IS a FIRE





What you want to know is
what is going on in the population?
All you have is sample data
Your hypothesis states there is a difference
between groups
Null hypothesis states there is NO difference
between groups
Even though your sample data show some
difference between groups, there is a chance
that there is no difference in population

Be conservative about your conclusion.
Unless you are highly confident, don’t
support your hypothesis over null
hypothesis

Since you cannot be 100% sure about
whether or not your conclusion is
correct, you take up to 5% risk (5%
chance making TYPE I Error)

Your p-value tells you the risk
(i.e., probability) of TYPE I Error
Significance Test

Significance test examines the probability
of TYPE I error (falsely rejecting H0)

Significance test examines how probable it
is that the observed difference is caused by
random sampling error

Reject the null hypothesis if probability is
<.05 (probability of TYPE I error
is smaller than .05)
P < .05
Reject Null Hypothesis (H0)
Support Your Hypothesis (Ha)
Logic of Hypothesis Testing
Statistical tests used in hypothesis testing deal with the
probability of a particular event occurring by chance.
Are the results common or a rare occurrence
if only chance is operating???
A score (or result of a statistical test) is “Significant”
if score is unlikely to occur on basis of chance alone.
Level of Significance
The “Level of Significance” is a cutoff point for determining
significantly rare or unusual scores.
Scores outside the middle 95% of a distribution are
considered “Rare” when we adopt the standard
“5% Level of Significance”
This level of significance can be written as:
p = .05
Decision Rules
Reject Ho (accept Ha) when
sample statistic is statistically significant at
chosen p level, otherwise accept Ho (reject Ha).
Possible errors:
•
You reject Null Hypothesis when in fact it is true,
Type I Error, or Error of Rashness.
B. You accept Null Hypothesis when in fact it is false,
Type II Error, or Error of Caution.
Ha: Female students have higher GPA
than Male students at UH
Sample
Population
?
Male GPA= 3.3
Female GPA = 3.6
N=100
Inferential
Parameter
Three Possibilities

Females really have
higher GPA than Males

Females with higher GPA
are disproportionately
selected because of
sampling bias

Females’ GPA happened
to be higher in this
particular sample due to
random sampling error
Male GPA= 3.3
Female GPA =3.6
What Statistics CANNOT do

Statistics canNOT think or reason. It’s
only you who can think.
Statistics can NOT show causality; can show
co-occurrence, which only implies causality.
 Statistics is about probability, thus
can NOT prove your argument.
It can only support it.
 We reject the null hypothesis if probability is
<.05 (probability of TYPE I error is smaller
than .05)

What Statistics CAN Do

Allow you to grasp a large picture

Examine the level of co-occurrence of
different events (correlation/association)

Can support your argument by providing
empirical evidence
Product Recognition
Comparison of Total Scores
14
Mean Score
13
12
11
10
9
Male Female
Gender
p=.02
17-26
27-33
Age
p=.001
34+
Single Married
Marital Status
p=.91
0-15
16-35
36+
Family Income
p=.004
Question:
How can I accurately tell if there is a meaningful
difference between the subgroups?
Answer:
Use Inferential Statistics techniques to help you
decide if the differences you found could be due to
chance, or if they a likely to reflect a true difference
between the groups.
Footnote:
Statistical jargon: If the differences are too large to be
due to chance, we say there is a Significant Difference
between the groups. We also know the probability that
our conclusions may be incorrect.
When comparing two groups on MEAN SCORES use the
t-test.
Mea n 1 - Mea n 2
t =
2
SD1
n1
+
2
SD2
n2
When you are comparing more than two groups on MEAN
SCORES, you use a more complicated version of the t-test,
called
Analysis of Variance.
p = .02
** Accept Ha
Males:
Mean scores reflect
real difference
between genders.
Mean = 11.3
SD = 2.8
n = 135
12.6
11.3
Accept Ho
Mean scores are just
chance differences from
a single distribution.
Females:
Mean = 12.6
SD = 3.4
n = 165
12
Married:
Accept Ha
Mean scores reflect
real difference
between groups.
Mean = 11.9
SD = 3.8
n = 96
12.1
11.9
Single:
Mean = 12.1
SD = 4.3
n = 204
12
p = .91
**Accept Ho
Mean scores are just
chance differences from
a single distribution.
To compare two groups on Mean Scores use the t-test.
For more than 2 groups use Analysis of Variance (ANOVA)
To compare survey data from Nominal or Ordinal Scales -without a Mean Score, so use a Nonparametric Tests.
Chi Square tests the difference in Frequency Distributions
of two or more groups.
When to use various statistics


Parametric
Interval or ratio data


Non-parametric
Use with ordinal and
nominal data
Parametric Tests

Used with data w/ mean score or standard
deviation.

t-test, ANOVA and Pearson’s Correlation r.



Use a t-test to compare mean differences
between two groups (e.g., male/female and
married/single).
Parametric Tests

use ANalysis Of VAriance (ANOVA) to
compare more than two groups (such as
age and family income) to get probability
scores for the overall group differences.

Use a Post Hoc Tests to identify which
subgroups differ significantly from each
other.
T-test

If p<.05, we conclude that two groups are
drawn from populations with different
distribution (reject H0) at 95% confidence
level