### Casio Graphics Calculator fx

```Casio Graphics Calculator
fx-9750GII
Guide for STAT 193
2013
This guide is for students in STAT193 using the fx-9750GII Casio Graphics Calculator.
Some students may have older versions of this calculator. Almost all of the functions of the fx9750GII are the same, or nearly so, on older calculators. However there are some differences,
and most importantly the older calculators cannot compute inverse T, inverse F and inverse
Chi-square probabilities. Printed statistical tables must be used for these calculations.
A Supplementary Guide is available for students with older calculators explains what the differences are, and how to use statistical tables.
Contents
1
Turning the calculator on and off
3
2
Important Keys
4
3
Clearing the calculator’s memory
4
4
Mathematical Calculations
5
5
Scientific Notation
6
6
Entering, Editing and Deleting Data
7
7
Summary Statistics for One Variable
8
7.1
Individual Values . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
8
7.2
Grouped Data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
9
8
Bivariate Data
10
8.1
Entering bivariate data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
10
8.2
Summary statistics for bivariate data, regression . . . . . . . . . . . . . . . . .
10
1
8.3
9
Prediction using a fitted regression line . . . . . . . . . . . . . . . . . . . . . .
11
Probability Distributions
13
9.1
Binomial Distribution . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
13
9.2
Normal Distribution . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
13
9.2.1
Normal Probabilities in Ranges . . . . . . . . . . . . . . . . . . . . .
14
9.2.2
Inverse Normal Probabilities . . . . . . . . . . . . . . . . . . . . . . .
15
t Distribution . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
17
9.3.1
t Probabilities in Ranges . . . . . . . . . . . . . . . . . . . . . . . . .
17
9.3.2
Inverse t Probabilities . . . . . . . . . . . . . . . . . . . . . . . . . . .
17
F Distribution . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
18
9.4.1
F Probabilities in Ranges . . . . . . . . . . . . . . . . . . . . . . . . .
18
9.4.2
Inverse F Probabilities . . . . . . . . . . . . . . . . . . . . . . . . . .
18
Chi-square Distribution . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
19
9.5.1
Chi-square Probabilities in Ranges . . . . . . . . . . . . . . . . . . . .
19
9.5.2
Inverse Chi-square Probabilities . . . . . . . . . . . . . . . . . . . . .
19
9.3
9.4
9.5
10 Large Sample Confidence Intervals
20
10.1 Large Sample Confidence Interval for µ . . . . . . . . . . . . . . . . . . . . .
20
10.2 Large Sample Confidence Interval for p . . . . . . . . . . . . . . . . . . . . .
21
10.3 Large Sample Confidence Interval for µ1 − µ2 . . . . . . . . . . . . . . . . . .
21
11 Large Sample Hypothesis Tests
22
11.1 Large Sample Hypothesis Test for µ . . . . . . . . . . . . . . . . . . . . . . .
22
11.2 Large Sample Hypothesis Test for p . . . . . . . . . . . . . . . . . . . . . . .
23
11.3 Large Sample Hypothesis Test for µ1 − µ2 . . . . . . . . . . . . . . . . . . . .
24
12 Small Sample Confidence Intervals
25
13 Small Sample Hypothesis Tests
26
14 Analysis of Variance – ANOVA
27
15 Chi-Squared Test
29
16 The Sign Test
30
2
1 Turning the calculator on and off
• Turn on: AC/ON
• Turn off: SHIFT AC/ON
The calculator will turn off automatically after a short time without activity. No data are lost
when the calculator does this.
3
2 Important Keys
• The REPLAY button – represented as
L
in these notes.
Use it to move around on the screen when needed.
• The MENU key accesses the main functions of the calculator.
Use
L
to move around to the panel you want, press EXE to select.
We will only need:
– RUN-MAT: For mathematical calculations;
– STAT: For statistical calculations;
– SYSTEM: To clear the calculator’s memory.
• At any stage the EXIT key will take you back one step, keep pressing it and you’ll end
up at the beginning screen for whichever MENU mode you’re in.
• You can switch backwards and forwards between RUN-MAT and STAT modes, and won’t
lose any data.
Do this when you want to do a mathematical calculation (using RUN-MAT mode) midway through a statistical analysis (using STAT mode).
3 Clearing the calculator’s memory
You will need to do this at the beginning of the final examination and in the term test.
It’s also worth clearing the menu every time you start a new statistical problem – it will clear
out any data that might be lurking in the calculator’s memory.
L
) to the SYSTEM panel; EXE
• F5 Reset
• F2 Main Memories
• F1 Yes – to rest the main memories
(this can take a few seconds)
• EXIT
• Then MENU to get you back to the menus to start working again.
NB: If you need to change settings on your calculator for some calculations, clearing the memory is a good way of making sure that everything is back to the way it was before you made any
changes, and that all the data are gone.
4
4 Mathematical Calculations
L
RUN-MAT; EXE .
Type in mathematical expressions, and evaluate using EXE .
Examples:
2+2
2 + 2 EXE
4.22
4 . 2 x2 EXE
6.2 − 3.1
3.4
( 6 . 2 − 3 . 1 ) ÷ 3 . 4 EXE
Be careful about when you need to use brackets ( and ) . Without brackets the last example
would evaluate 6.2 − 3.1
3.4 .
You can re-use the answer from one calculation in the next using SHIFT Ans .
Another example showing how to do a calculation in two stages using SHIFT Ans :
8 − 3.2
√
4+2
OR
( 8 − 3 . 2 ) ÷ SHIFT
8 − 3.2
√
4+2
8 − 3 . 2 EXE
SHIFT Ans ÷ SHIFT
√
√
( 4 + 2 ) EXE
( 4 + 2 ) EXE
NB: You can move in and out of RUN-MAT mode even when you’re in the middle of another
calculation in STAT mode. Use the MENU key to switch between them.
5
5 Scientific Notation
There is a standard way of expressing numbers that may be very large or very small.
Powers of ten are:
100 = 1
10−1 = 0.1
10−2 = 0.01
10−3 = 0.001
10−4 = 0.0001
10−5 = 0.00001
10−6 = 0.000001
..
.
101 = 10
102 = 100
103 = 1000
104 = 10000
105 = 100000
106 = 1000000
..
.
Use these powers of 10 to represent numbers in a compact form:
Number
Scientific
Calculator
Number
Notation
10334.5 = 1.03345 × 10000 = 1.03345 × 104 = 1.03345E+04
0.000024 = 2.4 × 0.00001 = 2.4 × 10−5
1
=
1×1
=
1 × 100
=
2.4E-05
=
1.0E+00
The EXP button on a calculator makes the ‘E’ when entering numbers in scientific notation.
Type
1E5
2.48E6
6.3E-1
4.443E-3
1 × 105
2.48 × 106
6.3 × 10−1
4.443 × 10−3
6
To get...
100000
2480000
0.63
0.00443
6 Entering, Editing and Deleting Data
You’ll see the List layout:
List 1
SUB
1
2
3
..
.
L
STAT; EXE .
List 2
List 3
List 4
..
.
You can move around this from one cell to another using
L
.
There is a set of menu items above the six function keys F1 , F2 , . . . , F6 :
GRPH
CALC
TEST
INTR
DIST
⊲
F1
F2
F3
F4
F5
F6
To select the menu item, press the function key directly below it.
For example F2 gives the CALC function. In these notes this is represented by F2 CALC.
Pressing F6 ⊲ gives a second set of function options
TOOL
EDIT
DEL
DEL-A
INS
⊲
F1
F2
F3
F4
F5
F6
And pressing F6 ⊲ again gives the original set.
• To enter data, move to the cell you want, type the number you want to enter, and press
EXE ;
The cursor will move down to the next cell below.
• To delete an item move to the cell you want to delete, and press DEL .
• To clear an entire list move the cursor into the list you want to clear, and press F4 DEL-A
(you may have to press F6 ⊲ first to find DEL-A).
Press F1 Yes to confirm that you do want to clear the data.
7
7 Summary Statistics for One Variable
7.1
L
STAT; EXE .
Individual Values
Data are the n = 9 values: 2, 5, 5, 8, 8, 8, 11, 11, 14
Input xi ’s individually into List 1:
2 EXE 5 EXE 5 EXE . . .
List 1
SUB
1
2
3
..
.
List 2
List 3
List 4
2
5
5
..
.
• F2 CALC
• F1 1VAR
1-Variable
x¯
=8
=72
∑x
=684
∑ x2
σx
=3.46410161
sx
=3.67423461
n
=9
minX
=2
Q1
=5
Med
=8
Q3
=11
maxX =14
Mod
=8
Mod:n =1
Mod:F =3
mean
sum ∑i xi
sum ∑i xi2
Std. Dev. σ (n)
Std. Dev. s (n − 1) ← use this one
Sample size
Smallest value
Lower Quartile (LQ)
Median
Upper Quartlie (UQ)
Largest value
Mode
Number of modes
Frequency at the mode
No matter which statistic you want, always check the sample size is right!
8
7.2
Grouped Data
Input xi ’s using frequencies:
2
1
xi
fi
5
2
8
3
11
2
14
1
Enter the xi ’s into List 1: 2 EXE 5 EXE 8 EXE 11 EXE 14
Enter the fi ’s into List 2: 1 EXE 2 EXE 3 EXE 2 EXE 1
SUB
1
2
3
4
5
List 1
List 2
2
5
8
11
14
1
2
3
2
1
List 3
List 4
The calculator assumes that List 1 is x, but we have to tell it that List 2 is f
• F2 CALC
• F6 SET
•
•
L
: 1Var XList; F1 LIST; 1 ; EXE
L
: 1Var Freq; F2 LIST; 2 ; EXE
• EXIT
• F1 1VAR
Always check the sample size is right! n = 9
You may need to set these list assignments back: best to clear the memories if you are unsure of
any setting.
9
8 Bivariate Data
8.1
Entering bivariate data
Example. Diameters at breast height of 14 chestnut oak trees for a sample of such trees grown
in poor soil.
Age (years)
xi
4
8
8
10
13
16
20
DBH (inches)
yi
0.8
1.0
3.0
3.5
3.5
4.5
5.5
Age (years)
xi
23
28
30
33
35
38
42
DBH (inches)
yi
4.7
6.0
6.0
8.0
7.0
7.0
7.5
Enter the data into Lists 1 and 2 in your calculator (STAT mode).
8.2
List 1
List 2
SUB
1
2
3
..
.
4
8
8
..
.
0.8
1.0
3.0
14
42
7.5
List 3
List 4
Summary statistics for bivariate data, regression
Once the data have been entered:
Oak Trees in Poor Soil
Draw a scatterplot of the data:
6
• •
•
•
•
•
•
•
•
•
•
•
0
• F2 GPH2
•
4
• F1 GRPH
2
Diameter at Breast Height
8
•
0
10
10
20
30
Age in Years
40
Then fit the line:
• EXIT EXIT back to the data
• F2 CALC
• F3 REG
• F1 X
• F2 a + bX ← NB: use this option or a, b are reversed
Reports statistics from linear regression:
a
b
r
r2
MSE
=1.0841
=0.1715
=0.9387
=0.8811
=0.6706
Intercept
Slope
Pearson’s Correlation Coefficient
Coefficient of Determination
s2
NOTE: To calculate Spearman’s correlation coefficient, replace the data with their ranks (taking
care to treat ties properly), and compute Pearson’s correlation coefficient for the ranks.
8.3
Prediction using a fitted regression line
After fitting the regression line go into RUN-MAT mode and set the calculator up to make
predictions:
• OPTN
L
RUN-MAT; EXE .
• F5 STAT
Then to predict Y for a particular value of X, e.g. X = 8:
• Type X value: 8
• F2 Yb
• EXE
Fitted value: Yb = 2.4562.
(8, 2.4562) is on the regression line.
11
Alternative Method for Prediction
If the data are already entered then graph the regression line
• F1 GRPH
• F2 GPH2
• F1 CALC
• F2 X
• F2 a + bX ← NB: use this option or a, b are reversed
• F6 DRAW
Now predict the points – go into prediction mode ‘G-Solv’:
• SHIFT F5 G-Solv
• F1 Y-CAL
Can now predict Y for any X: e.g. X = 8:
• Type X value: 8 EXE
Fitted value: Yb = 2.4562.
(8, 2.4562) is on the regression line.
12
9 Probability Distributions
9.1
Binomial Distribution
If X ∼ Binomial(n, p) then the calculator can compute
• Individual Probabilities: P(X = x)
• Cumulative Probabilities: P(X ≤ x)
Example.
X ∼ Binomial(15, 0.05)
Individual probability: compute P(X = 3):
Cumulative probability: compute P(X ≤ 2):
• F5 DIST
• F5 DIST
• F5 BINM
• F5 BINM
• F1 Bpd
(‘p’ for probability)
• F2 Bcd
(‘c’ for cumulative)
•
•
•
•
•
L
L
L
L
L
Data; F2 Var
•
x; 3 EXE
•
Numtrial; 1 5 EXE
•
p; 0 . 0 5 EXE
•
Execute; EXE
•
L
Data; F2 Var
L
Numtrial; 1 5 EXE
L
Execute; EXE
L
L
x; 2 EXE
p; 0 . 0 5 EXE
To calculate P(X ≥ x) use
P(X ≥ x) = 1 − P(X < x)
= 1 − P(X ≤ (x − 1))
e.g. P(X ≥ 3) = 1 − P(X ≤ 2) = 1 − 0.9638 = 0.0362.
Note: Can switch to RUN-MAT mode:
1 - SHIFT Ans EXE
Ans uses the last result from STAT mode 0.9638.
9.2
Normal Distribution
If X ∼ Normal(µ , σ 2 ) then the calculator can compute
• Probabilities in ranges: P(a < X < b)
• Inverse probabilities: given a probability p find:
– (Left): x∗ so that P(X < x∗ ) = P(−∞ < X < x∗ ) = p
– (Right): x∗ so that P(X > x∗ ) = P(x∗ < X < ∞) = p
– (Central): (x1∗ , x2∗ ) so that P(x1∗ < X < x2∗ ) = p
13
9.2.1
Normal Probabilities in Ranges
NB: Use ±9 × 1099 = ± 9E99 for plus or minus infinity (±∞) when calculating left and right
tail probabilities.
Example: Lengths of oysters follow a normal distribution with mean 81mm and standard deviation 12mm.
X ∼ Normal(81, 122 )
P(61<X<101)
Find P(61 < X < 101)
X~Normal(81,122)
• F5 DIST
• F1 NORM
• F2 Ncd
(‘c’ for cumulative)
•
•
•
•
•
•
L
Data; F2 Var
L
Upper; 1 0 1 EXE
L
Lower; 6 1 EXE
L
σ ; 1 2 EXE
L
Execute; EXE
L
61
81
µ ; 8 1 EXE
P(X>81)
Find P(X > 81)
X~Normal(81,122)
• F5 DIST
• F1 NORM
• F2 Ncd
(‘c’ for cumulative)
•
•
•
•
•
•
L
Data; F2 Var
L
Upper; 9 EXP 9 9 EXE
L
µ ; 8 1 EXE
L
Lower; 8 1 EXE
L
σ ; 1 2 EXE
L
Execute; EXE
81
14
101
P(X<50)
Find P(X < 50)
X~Normal(81,122)
• F5 DIST
• F1 NORM
• F2 Ncd
(‘c’ for cumulative)
•
•
•
•
•
•
L
Data; F2 Var
L
Lower; − 9 EXP
L
Upper; 5 0 EXE
L
µ ; 8 1 EXE
9 9 EXE
L
σ ; 1 2 EXE
L
Execute; EXE
50
81
Answer is 0.00489 = 4.8925 × 10−3 = 4.8925E − 03
Note: When calculating P(x1 < X < x2 ) for X ∼ Normal(µ , σ 2 ), the calculator also reports the
standardised versions (z1 , z2 ) of (x1 , x2 ):
z1 =
x1 − µ
σ
and
z2 =
x2 − µ
σ
for which
P = P(x1 < X < x2 ) = P(z1 < Z < z2 )
with Z ∼ Normal(0, 1).
9.2.2
Inverse Normal Probabilities
Example: Lengths of oysters follow a normal distribution with mean 81mm and standard deviation 12mm.
X ∼ Normal(81, 122 )
Find x∗ so that P(X < x∗ ) = 0.75
i.e. the Upper Quartile of the distribution of X.
(The area 0.75 is to the Left)
• F5 DIST
Shaded Area = 0.75 = P(X<UQ)
X~Normal(81,122)
75%
• F1 NORM
• F3 InvN
(Inverse Normal)
•
•
•
•
•
•
L
Data; F2 Var
L
Area; 0 . 7 5 EXE
L
Tail; F1 Left
L
σ ; 1 2 EXE
L
Execute; EXE
L
81 UQ
µ ; 8 1 EXE
15
x∗
= 89.09
Find x∗ so that P(X > x∗ ) = 0.40
(The area 0.40 is to the Right)
Shaded Area = 0.40 = P(X>x*)
X~Normal(81,122)
• F5 DIST
• F1 NORM
• F3 InvN
(Inverse Normal)
•
•
•
•
•
•
L
Data; F2 Var
L
Area; 0 . 4 0 EXE
L
Tail; F2 Right
L
σ ; 1 2 EXE
L
Execute; EXE
L
40%
81
µ ; 8 1 EXE
Find (x1∗ , x2∗ ) so that P(x1∗ < X < x2∗ ) = 0.80
(The area 0.80 is at the Centre)
Shaded Area = 0.80 = P(−x1<X<x2)
X~Normal(81,122)
• F5 DIST
• F1 NORM
• F3 InvN
(Inverse Normal)
•
•
•
•
•
•
L
Data; F2 Var
L
Area; 0 . 8 0 EXE
L
Tail; F3 CNTR
L
σ ; 1 2 EXE
L
Execute; EXE
L
80%
x1
µ ; 8 1 EXE
Answer is (x1∗ , x2∗ ) = (65.621, 96.379)
16
81
x2
9.3
t Distribution
If T ∼ td = a t-distribution with d degrees of freedom then the calculator can compute
• Probabilities in ranges: P(a < T < b)
• Inverse probabilities: given a probability p find:
– (Right): td∗ so that P(T > td∗ ) = P(td∗ < X < ∞) = p
9.3.1
t Probabilities in Ranges
NB: Use ±9 × 1099 = ±9E99 for plus or minus infinity (±∞) when calculating left and right
tail probabilities.
Find P(t12 > 1.31)
P(T>1.31)
• F5 DIST
t5
• F2 t
• F2 tcd
(‘c’ for cumulative)
•
•
•
•
•
L
Data; F2 Var
L
Upper; 9 E 9 9 EXE
L
Execute; EXE
L
L
Lower; 1 . 3 1 EXE
df; 1 2 EXE
0
1.31
9.3.2
Inverse t Probabilities
Find t ∗ so that P(t12 > t ∗ ) = 0.20
Shaded Area = 0.20 = P(T>t*)
• F5 DIST
t5
• F2 t
• F3 Invt
•
•
•
•
•
L
Data; F2 Var
L
Upper; 9 E 9 9 EXE
L
Execute; EXE
L
L
20%
Area; 0 . 2 0 EXE
df; 1 2 EXE
t*
Answer is t ∗ = 0.87261
17
9.4
F Distribution
If F ∼ F(d1,d2) = an F-distribution with (d1 , d2 ) degrees of freedom then the calculator can
compute
• Probabilities in ranges: P(a < F < b)
• Inverse probabilities: given a probability p find:
∗
∗
∗
< F < ∞) = p
) = P(F(d1,d2)
so that P(F > F(d1,d2)
– (Right): F(d1,d2)
9.4.1
F Probabilities in Ranges
Find P(F(5,12) > 2.75)
P(F>2.75)
• F5 DIST
F5,20
• F4 F
• F2 Fcd
(‘c’ for cumulative)
•
•
•
•
•
•
L
Data; F2 Var
L
Upper; 9 E 9 9 EXE
L
Lower; 2 . 7 5 EXE
L
n:df; 5 EXE
L
Execute; EXE
L
d:df;
df=d2)
1
2
(numerator df=d1)
EXE
0
2.75
(denominator
9.4.2
Inverse F Probabilities
Find F ∗ so that P(F(5,12) > F ∗ ) = 0.10
Shaded Area = 0.10 = P(F>F*)
• F5 DIST
F5,20
• F4 F
• F3 InvF
•
•
•
•
•
L
Data; F2 Var
L
n:df; 5 EXE
L
L
Area; 0 . 1 EXE ;
d:df;
df=d2)
L
1
2
10%
(numerator df=d1)
EXE
(denominator
0
Execute; EXE
Answer is F ∗ = 2.3940
18
F*
9.5
Chi-square Distribution
If X 2 ∼ χd2 = a χ 2 -distribution with d degrees of freedom then the calculator can compute
• Probabilities in ranges: P(a < X 2 < b)
• Inverse probabilities: given a probability p find:
– (Right): χd2∗ so that P(X 2 > χd2∗ ) = P(χd2∗ < X 2 < ∞) = p
9.5.1
Chi-square Probabilities in Ranges
Find P(χ32 > 4.12)
P(X2>4.12)
• F5 DIST
χ23
• F3 CHI
• F2 Ccd
(‘c’ for cumulative)
•
•
•
•
•
L
Data; F2 Var
L
Upper; 9 E 9 9 EXE
L
Execute; EXE
L
L
Lower; 4 . 1 2 EXE
df; 3 EXE
0
4.12
9.5.2
Inverse Chi-square Probabilities
Find χ 2∗ so that P(X32 > χ 2∗ ) = 0.05
Shaded Area = 0.05 = P(X2>χ2*)
• F5 DIST
χ23
• F3 CHI
• F3 InvC
•
•
•
•
L
Data; F2 Var
L
df; 3 EXE
L
L
Area; 0 . 0 5 EXE
5%
Execute; EXE
χ2*
19
10
Large Sample Confidence Intervals
Large sample confidence intervals can be calculated for means, differences in means, proportions, differences in proportions when sample sizes are large n ≥ 30. For two sample intervals
(differences in means or proportions) both samples must be large (n1 ≥ 30 and n2 ≥ 30).
To compute a large sample confidence interval
• F4 INTR (Interval)
• F1 Z (Large sample)
• Choose one of:
– F1 1-S: CI for µ (mean of one pop.)
– F2 2-S: CI for µ1 − µ2 (mean difference between two pops.)
– F3 1-P: CI for p (proportion in one pop.)
– F4 2-P: CI for p1 − p2 (difference in proportion between two pops.)
• ... Specify other information depending on the choice above
including the confidence level (e.g. 95%)
The calculator produces a pair of numbers: (Left, Right) = the confidence interval.
10.1
Large Sample Confidence Interval for µ
Example. When x¯ = 27.6, s = 4 and n = 40.
Create a 95% confidence interval for the population mean µ .
• F4 INTR (Interval)
• F1 Z
• F1 1-S
•
•
•
•
•
•
(Large sample)
(One sample)
L
Data; F2 Var
L
σ ; 4 EXE
L
L
L
L
C-Level; 0 . 9 5 EXE
(Confidence level)
(This is s)
x;
¯ 2 7 . 6 EXE
n; 4 0 EXE
Execute; EXE
Gives (26.36, 28.84).
20
10.2
Large Sample Confidence Interval for p
In addition to having n ≥ 30 must also check that
r
p(1 − p)
p±3
n
is inside the range (0,1). A quick way to check this is to construct a 99.7% interval, and see if it
is in the range (0,1). (The calculator is dumb enough to create confidence intervals outside this
range without reporting an error!)
Example. When X = 26 and n = 40.
Create a 98% confidence interval for the population proportion p.
• F4 INTR (Interval)
• F1 Z
• F3 1-P
•
•
•
•
L
(Large sample)
(One proportion)
C-Level; 0 . 9 8 EXE
L
x; 2 6 EXE
L
Execute; EXE
L
(Confidence level)
n; 4 0 EXE
Gives (0.475, 0.825).
10.3
Large Sample Confidence Interval for µ1 − µ2
Example.
n1 = 50
x¯1 = 26.1
s1 = 3.6
n2 = 40
x¯2 = 30.5
s2 = 5.4
Create a 95% confidence interval for µ1 − µ2
• F4 INTR (Interval)
• F1 Z
• F2 2-S
•
•
•
•
•
•
•
•
•
(Large sample)
(Two samples)
L
Data; F2 Var
L
L
x1;
¯ 2 6 . 1 EXE
L
C-Level; 0 . 9 5 EXE
(Confidence level)
σ 1; 3 . 6 EXE
(This is s1 )
L
σ 2; 5 . 4 EXE
(This is s2 )
L
n1; 5 0 EXE
L
n2; 4 0 EXE
L
L
x2;
¯ 3 0 . 5 EXE
Execute; EXE
Gives (−6.35, −2.45)
21
11
Large Sample Hypothesis Tests
Large sample hypothesis tests can be carried out for means, differences in means, proportions,
differences in proportions when sample sizes are large n ≥ 30. In two sample tests both samples
must be large (n1 ≥ 30 and n2 ≥ 30).
To carry out a large sample hypothesis test
• F3 TEST
• F1 Z (Large sample)
• Choose one of:
– F1 1-S: Test H0 : µ = µ0 (mean of one pop.)
– F2 2-S: Test H0 : µ1 − µ2 = 0 (mean difference between two pops.)
– F3 1-P: Test H0 : p = p0 (proportion in one pop.)
– F4 2-P: Test H0 : p1 − p2 = 0 (difference in proportion between two pops.)
• ... Specify other information depending on the choice above
including the type of alternative hypothesis (one or two sided)
The calculator produces a test statistic value (Z) and a p-value, as well as other information
depending on the chosen test.
Use the p-value to determine the outcome of the test at chosen significance level α (reject H0 if
p-value < α ).
To determine the critical value Z ∗ for the test statistic Z which specifies the rejection region,
use the Inverse Normal function of the calculator.
The rejection region may be one or two sided depending on H1 . Find Z ∗ so that
Two sided
P(Z > Z ∗ ) = α2
One sided (right) P(Z > Z ∗ ) = α
One sided (left)
P(Z < Z ∗ ) = α
(Always sketch the rejection region)
To find Z ∗ use the methods in Section 9.2.2.
11.1
Large Sample Hypothesis Test for µ
Example. Have sample information x¯ = 10.2, s = 2.3 and n = 30.
Test the hypotheses
H0 : µ = 9.4
H1 : µ 6= 9.4
A two-sided test.
• F3 TEST
• F1 Z
• F1 1-S
•
•
L
L
(Large sample)
(One sample)
Data; F2 Var
µ ; F1 6= µ 0
(2 sided)
22
•
•
•
•
•
L
L
L
L
L
µ 0; 9 . 4 EXE
σ ; 2 . 3 EXE
x;
¯ 1 0 . 2 EXE
n; 3 0 EXE
Execute; EXE
Result: Test Statistic, Z = 1.905, p-value = 0.05676.
Critical value Z ∗ for a two-sided α = 5% test: find Z ∗ so that P(Z > Z ∗ ) = 0.05/2 = 0.025 for
Z ∼ N(0, 1):
• F5 DIST
• F1 NORM
• F3 InvN
(Inverse Normal)
•
•
•
•
•
•
L
Data; F2 Var
L
Area; 0 . 0 2 5 EXE
L
Tail; F2 Right
L
σ ; 1 EXE
L
Execute; EXE
L
µ ; 0 EXE
Answer is Z ∗ = 1.96.
The rejection region is Z < −1.96 or Z > +1.96.
11.2
Large Sample Hypothesis Test for p
In addition to having n ≥ 30 must also check that
r
p(1 − p)
p±3
n
is inside the range (0,1). A quick way to check this is to construct a 99.7% confidence interval
for p, and see if it is in the range (0,1). (The calculator is dumb enough to create confidence
intervals outside this range without reporting an error!)
Example. Have sample information x = 26 successes in n = 40 independent Binomial trials.
Test the hypotheses
H0 : p = 0.60
H1 : p > 0.60
A one-sided test.
• F3 TEST
• F1 Z
• F3 1-P
•
L
(Large sample)
(One proportion)
Prop; F3 >
(1 sided, >)
23
•
•
•
•
L
L
L
L
p0; 0 . 6 EXE
x;
¯ 2 6 EXE
n; 4 0 EXE
Execute; EXE
Result: Test Statistic, Z = 0.6455, p-value = 0.25930.
11.3
Large Sample Hypothesis Test for µ1 − µ2
Example. Given data
n1 = 50
x¯1 = 26.1
s1 = 3.6
n2 = 40
x¯2 = 30.5
s2 = 5.4
Test the hypotheses:
H0 : µ1 = µ2
H1 : µ1 < µ2
One sided.
• F3 TEST
• F1 Z
• F2 2-S
•
•
•
•
•
•
•
•
•
(Large sample)
(Two Samples)
L
Data; F2 Var
L
L
x1;
¯ 2 6 . 1 EXE
L
µ 1; F2 < µ 2
(1 sided, <)
σ 1; 3 . 6 EXE
(This is s1 )
L
σ 2; 5 . 4 EXE
(This is s2 )
L
n1; 5 0 EXE
L
n2; 4 0 EXE
L
L
x2;
¯ 3 0 . 5 EXE
Execute; EXE
Result: Test Statistic, Z = −4.426, p-value = 4.7956E − 06 = 0.00000479.
24
12
Small Sample Confidence Intervals
For small samples (n < 30) of Normally distributed data.
To compute a small sample confidence interval
• F4 INTR (Interval)
• F2 t (Small sample)
• Choose one of:
– F1 1-S: CI for µ (mean of one pop.)
– F2 2-S: CI for µ1 − µ2 (mean difference between two pops.)
• ... Specify other information depending on the choice above
including the confidence level (e.g. 95%)
The calculator produces a pair of numbers: (Left, Right) = the confidence interval.
Example. When x¯ = 30.6, sx = 9.5 and n = 20.
Create a 95% confidence interval for the population mean µ .
• F4 INTR (Interval)
• F2 t
• F1 1-S
•
•
•
•
•
•
(Small sample)
(One sample)
L
Data; F2 Var
L
x;
¯ 3 0 . 6 EXE
L
C-Level; 0 . 9 5 EXE
L
sx; 9 . 5 EXE
L
Execute; EXE
L
(Confidence level)
n; 2 0 EXE
Gives (26.2, 35.0).
25
13
Small Sample Hypothesis Tests
For small samples (n < 30) of Normally distributed data.
To carry out a small sample hypothesis test
• F3 TEST
• F2 t (small sample)
• Choose one of:
– F1 1-S: Test H0 : µ = µ0 (mean of one pop.)
– F2 2-S: Test H0 : µ1 − µ2 = 0 (mean difference between two pops.)
– F3 REG: Test H0 : β = 0 (slope of regression line)
• ... Specify other information depending on the choice above
including the type of alternative hypothesis (one or two sided).
For a two sample test, choose Pooled ‘on’ if the population variances are assumed to be
equal, ‘off’ if they differ.
The calculator produces a test statistic value (t) and a p-value, as well as other information
depending on the chosen test.
Use the p-value to determine the outcome of the test at chosen significance level α (reject H0 if
p-value < α ).
To determine the critical value td∗ for the test statistic t with d degrees of freedom which specifies
the rejection region, use the Inverse t-distribution function of the calculator. (Note that this
function only calculates upper tails, so will need to change the sign of t ∗ for a left tailed rejection
region.)
The rejection region may be one or two sided depending on H1 . Find td∗ so that
Two sided
P(td > td∗ ) = α2
One sided (right) P(td > td∗ ) = α
One sided (left)
P(td < td∗ ) = α
(Always sketch the rejection region)
To find td∗ use the methods in Section 9.2.2, but choose F2 t and F3 Invt (instead of F1
NORM and F3 InvN). You will need to specify the number of degrees of freedom for the test.
Example. Have sample information x¯ = 30.6, s = 9.5 and n = 20.
Test the hypotheses
H0 : µ = 25.6
H1 : µ > 25.6
A one-sided test.
• F3 TEST
• F2 t
• F1 1-S
•
•
L
L
(Small sample)
(One sample)
Data; F2 Var
µ ; F3 > µ 0
(1 sided)
26
•
•
•
•
•
L
L
µ 0; 2 5 . 6 EXE
x;
¯ 3 0 . 6 EXE
L
sx; 9 . 5 EXE
L
Execute; EXE
L
n; 2 0 EXE
Result: Test Statistic, t = 2.354, p-value = 0.01475.
The degrees of freedom of the test are n − 1 = 19
∗ for a one-sided α = 5% test: find t ∗ so that P(t > t ∗ ) = 0.05:
Critical value t19
19
19
19
• F5 DIST
• F2 t
• F3 Invt
(Inverse Normal)
•
•
•
L
L
L
Area; 0 . 0 5 EXE
df; 1 9 EXE
Execute; EXE
∗ = 1.729.
The rejection region is T > 1.729.
14
Analysis of Variance – ANOVA
Example. Driver reaction times for 3 age groups.
65+
X1
35
20
32
27
Age Groups
45-64 25-44
X2
X3
18
14
10
3
21
16
14
10
13
11
12
Observe differences in their reaction times X¯1 , X¯2 , X¯3 . Are these differences due to different
ages (treatment effects) or are they just ordinary variation within drivers?
Enter the data into Lists 1 and 2 in your calculator (STAT mode).
List 2 contains the observations, and List 1 contains the group number of each observation.
e.g. Group 1 contains the observations 35, 20, 32, 27, Group 2 contains 18, 10, 21, 14, 13, and
Group 3 contains 14, 3, 16, 10, 11, 12.
27
List 1
List 2
1
1
1
1
2
2
2
2
2
3
3
3
3
3
3
35
20
32
27
18
10
21
14
13
14
3
16
10
11
12
SUB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
List 3
List 4
Once the data have been entered:
• F3 TEST
• F5 ANOV
•
•
•
•
L
L
L
L
How many; F1 1
Factor A; F1 List; 1 EXE
Dependnt; F1 List; 2 EXE
Execute; EXE
Gives the first two rows of the ANOVA table, the F statistic value (15.032), and the p-value
(0.00053).
df
SS
MS
F
P
A
2 761.13 380.56 15.032 5.3E-4
ERR 12 303.80 25.316
Use the p-value to determine the outcome of the test at chosen significance level α (reject H0 if
p-value < α ).
∗
To determine the critical value Fd1,d2
for the test statistic F with (d1, d2) degrees of freedom
which specifies the rejection region, use the Inverse F-distribution function of the calculator.
∗
∗
For ANOVA the rejection region is always one-sided. So find Fd1,d2
so that P(F > Fd1,d2
) = α.
∗
∗
In the example if α = 0.01 then we need F(2,12)
) = 0.01:
so that P(F > F(2,12)
• F5 DIST
• F4 F
(for F distribution)
• F3 InvF
•
•
•
•
•
L
Data: F2 Var EXE
L
n:df: 2 EXE ;
L
Execute; EXE
L
L
Area: 0 . 0 1 EXE
(α )
(Numerator df)
d:df: 1 2 EXE ;
(Denominator df)
Gives F ∗ = 6.9266: Rejection region is F > 6.9266.
28
15
Chi-Squared Test
Example. Married adults with at least one child reported their family type (intact or other) and
whether they experienced violent acts of spouse abuse in the past year.
None
Abuse
Intact
743
36
Other
170
11
Test whether family type and experience of abuse are associated:
• F3 TEST
• F3 CHI
• F2 2WAY
•
•
•
•
(Use 2-Way because we have crosstabulated 2 variables)
L
Observed; F2 ⊲MAT
L
m; 2 EXE
L
L
Mat A; F3 DIM
n; 2 EXE EXE
• 7 4 3 EXE
• 1 7 0 EXE
• 3 6 EXE
• 1 1 EXE
• EXIT EXIT
•
L
Execute; EXE
Result: Test statistic, χ 2 = 0.669, p-value = 0.41349.
To view the table of expected values, when looking at the output of the test go
• F6 ⊲MAT
•
L
Mat B; EXE
You can then check whether the Chi-squared test is valid: it requires 80% of cells to have
expected values ≥ 5. Go EXIT EXIT to get back to the test output screen.
To determine the critical value χd2∗ for the test statistic X 2 with d degrees of freedom which
specifies the rejection region, use the Inverse χ 2 -distribution function of the calculator.
For the Chi-squared test the rejection region is always one-sided. So find χd2∗
so that P(X 2 > χd2∗ ) = α .
In the example we have (r − 1)(c − 1) = (2 − 1)(2 − 1) = 1 degree of freedom. If α = 0.01 then
we need χ12∗ so that P(X 2 > χ12∗ ) = 0.01:
• F5 DIST
• F3 CHI
(for χ 2 distribution)
29
• F3 InvC
•
•
•
•
L
Data: F2 Var EXE
L
df: 1 EXE ;
L
L
(α )
Area: 0 . 0 1 EXE
Execute; EXE
Gives χ12∗ = 6.6349: Rejection region is X 2 > 6.6349.
16
The Sign Test
Example. Lengths of a certain bone in the skeletons of 9 recently discovered human ancestors
were:
2.75, 2.14, 3.23, 2.07, 2.49, 2.28, 3.16, 2.93, 2.20
In Australopithicus, the median length of this bone is 2.2 cm.
Test the hypotheses
H0 : m = 2.2
H1 : m > 2.2
A one-sided test.
To values > 2.2 assign a + (overs)
To values < 2.2 assign a − (unders)
To values = 2.2 assign a 0.
Gives: + − + − + + + + 0
Drop any 0’s and reduce sample size accordingly. Gives n′ = 8, 2− and 6+.
If H0 is true then
X ∼ Binomial(8, 0.5)
Cumulative probability: compute P(X ≥ 6):
P(X ≥ 6) = 1 − P(X ≤ 5)
• F5 DIST
• F5 BINM
• F2 Bcd
(‘c’ for cumulative)
•
•
•
•
•
L
Data; F2 Var
L
Numtrial; 8 EXE
L
Execute; EXE
L
L
x; 5 EXE
p; 0 . 5 EXE
Answer is P(X ≤ 5) = 0.8555, so
p-value = 1 − 0.8555 = 0.1445
Use the p-value to determine the outcome of the test at chosen significance level α (reject H0 if
p-value < α ).
30
```