Coded Totals and Combining Two Data Sets | Cambridge A Level Maths notes
Free preview: Coded Totals and Combining Two Data Sets
Coded Totals: Σ(x − a) and Σ(x − a)²
9709 Paper 5: Probability & Statistics 1
Let's start with a problem. Squaring and adding numbers like 1020, 1030 and 1090 by hand is slow and easy to get wrong. , and you need five of those. Can we make the numbers smaller first, and still get the right mean and standard deviation at the end?
- Coding means changing every data value by the same simple rule, usually to make the numbers smaller.
- In this course the code is almost always a shift: subtract the same number a from every value.
- Questions then give you the coded totals Σ(x − a) and Σ(x − a)² instead of Σx and Σx².
- Your job is to get the mean and standard deviation of the original x values from these totals.
What happens to the mean
- Subtracting a from every value moves the whole data set down by a.
- So the mean of the values x − a is the mean of x, minus a.
- To get back, add a on again:
What happens to the spread
- Every value moves by the same amount, so the gaps between values do not change.
- So the standard deviation of x − a is exactly the standard deviation of x.
- Use the usual formula with x − a in place of x:
💡 In plain words
- The mean needs a added back on. The standard deviation does not.
- The bracket squared at the end is the square of the coded mean, not of the real mean.
- Here's the trap: do not write (the real mean squared) in the variance formula with coded totals.
Recipe: mean and standard deviation from coded totals
- Find the coded mean . Why: it is the mean of the shifted values.
- Add a back on to get . Why: the shift moved the mean down by a.
- Variance: minus the coded mean squared. Why: the same formula, with x − a in place of x.
- Square root for σ, and do not add a. Why: a shift never changes spread.
👀 Watch me do it: five masses 1020, 1030, 1050, 1060, 1090 g, with a = 1000
| What I write | Why I do it |
|---|---|
| Subtract 1000: 20, 30, 50, 60, 90 | a is just below every value, so the numbers left are small. |
| Σ(x − 1000) = 250, Σ(x − 1000)² = 400 + 900 + 2500 + 3600 + 8100 = 15 500 | The coded totals: easy to square and add. |
| g | Steps 1 and 2: coded mean 50, then add a back on. |
| Step 3: square the coded mean, 50, not 1050. | |
| g (3 s.f.) | Step 4. The 1000 came back for the mean but played no part in the standard deviation. |
📝 Here's the trap
- Wrong: . That gives a huge negative number, and a variance can never be negative.
- Right: subtract the square of the coded mean, . Coded totals go with the coded mean.
Unlock the full note: start 7 days free.
Log in or subscribe to read the rest of this note. Members also get the AI tutor, practice quizzes, mock exams and flashcards for this topic.
All notes in Representation of data (5.1)
- Stem-and-Leaf Diagrams, Including Back-to-Back
- Types of Data and the Mean, Median and Mode
- Grouped Data: Estimating the Mean, Median, Quartiles and Percentiles
- Measuring Spread: Range, Interquartile Range, Variance and Standard Deviation
- Cumulative Frequency Diagrams and Box Plots
- Histograms, Frequency Density and the Shape of a Distribution
- Coded Totals and Combining Two Data Sets
- Outliers and Choosing How to Present Data
What's inside for this topic
8 teacher notes, 157 practice questions, 40 flashcards, 2 quizzes.
Get the full notes, every practice question, flashcards, quizzes and mock papers.
Previous note: Histograms, Frequency Density and the Shape of a Distribution Next note: Outliers and Choosing How to Present Data