How to do a t-test and a χ² test on the Casio fx-CG50
Two-sample t-test (pooled), χ² test for independence from a contingency table and χ² goodness of fit. Exact keystrokes for the fx-CG50 first, then the other calculators, a worked example you can check your answers against, the mistakes that cost marks, and the same thing in Desmos.
When you need it
χ² contingency tables and goodness-of-fit tests are in Further Statistics (and IAL S3); t-tests appear in some Further Statistics options. A Level Maths itself only tests the binomial, normal and correlation.
Practise it: Hypothesis testing.
Keystrokes on your calculator
Pick your calculator: the page remembers it next time.
t-tests and χ² tests on the Casio fx-CG50
Written for OS 3.80 (menus unchanged from OS 3.60 onwards as far as we can tell). Casio fx-CG50: graphic (GDC).
- t-test: MENU 2, sample A in List 1 and sample B in List 2. F3 (TEST) F2 (t) F2 (2-SAMPLE).
- Data: List, μ1: ≠ μ2, List(1): List1, List(2): List2, Freq 1 and 1, Pooled: On. Execute: read t, p and df.
- χ² independence: F3 (TEST) F3 (CHI) F2 (2WAY). Observed: Mat A. Press F2 (►MAT) to type the table into Mat A (set its size, e.g. 2 × 3), EXIT, then Execute. Read χ², p and df; the expected values are stored in Mat B.
- Goodness of fit: observed in List 1, expected in List 2 (expected frequencies, not proportions), then F3 (TEST) F3 (CHI) F1 (GOF). df = number of classes − 1 (minus any estimated parameters). Execute.
- p = 4.2056E−03 means 0.0042056: read the E−03.
- To see the expected frequencies: MENU 1, F3 (MAT/VCT), open Mat B.
t-tests and χ² tests on the TI-84 Plus CE
Written for OS 5.8.x. TI-84 Plus CE: graphic (GDC); also the TI-84 Plus CE Python / CE-T Python Edition.
- t-test: data in L1 and L2. stat → TESTS → 4: 2-SampTTest. Inpt: Data, List1 L1, List2 L2, μ1: ≠μ2, Pooled: Yes. Calculate.
- χ² independence: 2nd x⁻¹ (MATRIX) → EDIT → 1: [A], size 2 × 3, type the table. Then stat → TESTS → C: χ²-Test, Observed [A], Expected [B]. Calculate.
- Goodness of fit: observed in L1, expected in L2. stat → TESTS → D: χ²GOF-Test, Observed L1, Expected L2, df 3. Calculate.
- The expected table is written to [B]: view it in the MATRIX menu.
t-tests and χ² tests on the TI-Nspire CX II
Written for OS 6.x. TI-Nspire CX II: graphic (GDC), non-CAS; the CX II CAS is not allowed in IB, A Level or IGCSE exams.
- t-test: data in two named columns. menu → Statistics → Stat Tests → 2-Sample t Test → Data. Choose the lists, Alternate Hyp μ1 ≠ μ2, Pooled: Yes. OK.
- χ² independence: store the table as a matrix (e.g. obs := 18,22,20][32,18,10 on a Calculator page), then menu → Statistics → Stat Tests → χ² 2-way Test, Observed Matrix: obs.
- Goodness of fit: menu → Statistics → Stat Tests → χ² GOF with the observed and expected lists and df.
- stat.expmatrix holds the expected frequencies after a 2-way test.
t-tests and χ² tests on the Casio fx-991EX ClassWiz
Written for the fixed ROM (these models take no OS updates). Casio fx-991EX ClassWiz: scientific (no graphs).
The fx-991EX has no hypothesis tests. You can find a χ² statistic by hand (Σ(O − E)² ÷ E, with the table in a spreadsheet), but you then need χ² tables for the critical value; the t-distribution is not available at all.
t-tests and χ² tests on the Casio fx-991CW ClassWiz
Written for the fixed ROM (these models take no OS updates). Casio fx-991CW ClassWiz: scientific (no graphs); the newer ClassWiz with a HOME menu of apps.
The fx-991CW has no hypothesis tests. The Spreadsheet app can work out Σ(O − E)² ÷ E, but the critical value has to come from tables.
Worked example
(a) Sample A: 23.1, 25.4, 22.8, 26.0, 24.7, 25.9, 23.5, 24.2. Sample B: 21.9, 23.0, 22.4, 24.1, 21.5, 22.8, 23.3, 22.0. Test at 5% whether the means differ (pooled). (b) Observed table 18, 22, 20], [32, 18, 10: test for independence at 5%. (c) Observed 28, 35, 22, 15 against a uniform distribution.
Answers (checked with Python)
(a) t = 3.41266, p = 0.00420561 < 0.05: reject H₀, the means differ. (b) χ² = 7.65333, df = 2, p = 0.0217821 < 0.05: reject H₀ (not independent). The first expected frequency is 25. (c) χ² = 8.72, df = 3, p = 0.0332549 < 0.05: the data do not fit a uniform distribution.
Common calculator mistakes
- Pooled: the IB's two-sample t-test uses the pooled variance (Pooled: On/Yes). Leaving it off gives a slightly different p.
- Goodness of fit with proportions or percentages in the expected list: expected values must be frequencies that add up to the total.
- Wrong degrees of freedom: (rows − 1)(columns − 1) for independence; classes − 1 − (number of estimated parameters) for goodness of fit.
- Expected frequencies below 5: combine classes first (the calculator will not warn you).
- Concluding "H₀ is true": say there is insufficient evidence to reject H₀, and answer in the context of the question.
Do it in Desmos
Not in the exam. Desmos is not allowed in A Level exams. Use it to learn, to check a calculator answer, and to see what a function or data set looks like.
- Make lists A and B of the two samples.
- ittest(A, B) runs a two-sample t-test and shows t and p; choose the alternative hypothesis in its menu. Check whether it is pooled: if its p differs slightly from your GDC's pooled test, that is why.
- Desmos has no built-in χ² test: work out Σ(O − E)² ÷ E with lists (O and E) to check the statistic.
The interactive graph loads here when you scroll to it.
Or open desmos.com/calculator and type:
A=[23.1,25.4,22.8,26,24.7,25.9,23.5,24.2]B=[21.9,23,22.4,24.1,21.5,22.8,23.3,22]ittest(A,B)O=[28,35,22,15]E=[25,25,25,25]total(frac{(O-E)^{2}}{E})
More calculator skills
Sources
- Casio fx-CG50 Software User's Guide, OS 3.70 (PDF) : Casio fx-CG50, OS 3.80 (menus unchanged from OS 3.60 onwards as far as we can tell).
- TI-84 Plus CE guidebook (Texas Instruments) : TI-84 Plus CE, OS 5.8.x.
- TI-Nspire CX II guidebooks (Texas Instruments) : TI-Nspire CX II, OS 6.x.
- Casio fx-991EX / fx-570EX Quick Start Guides : Casio fx-991EX ClassWiz, the fixed ROM (these models take no OS updates).
- Casio fx-991CW / fx-570CW User's Guide : Casio fx-991CW ClassWiz, the fixed ROM (these models take no OS updates).
- Desmos Help Center for the Desmos functions.
Menu names are taken from each manufacturer's manual for the OS versions shown. Menus can move slightly between OS updates: if a screen looks different on yours, the manual for your version is the reference, and please tell us so we can update this page. Worked-example answers were recomputed independently in Python.