// Numbas version: exam_results_page_options {"name": "Measures of central tendency-Q3", "extensions": ["stats"], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"ungrouped_variables": ["meanab", "meana", "modea", "mediana", "meanb", "modeb", "medianb", "rangea", "rangeb", "suma", "sumb"], "name": "Measures of central tendency-Q3", "variable_groups": [{"variables": ["random2", "a1", "a2", "a3", "a4", "a5", "a6", "a7", "a8", "a9", "a10", "alist", "a", "asort"], "name": "A"}, {"variables": ["random", "b1", "b2", "b3", "b4", "b5", "b6", "b7", "b8", "b9", "b10", "blist", "b", "bsort"], "name": "B"}], "variablesTest": {"condition": "\n", "maxRuns": 100}, "statement": "

There is subtle variation from one step to the next when you walk. When the neuromuscular control of walking deteriorates due to ageing or neurological disease, steps become less consistent. The following table shows the step length from 10 steps for two people. 

\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n
Sally (cm)$\\var{a[0]}$$\\var{a[1]}$$\\var{a[2]}$$\\var{a[3]}$$\\var{a[4]}$$\\var{a[5]}$$\\var{a[6]}$$\\var{a[7]}$$\\var{a[8]}$$\\var{a[9]}$
Kate (cm)$\\var{b[0]}$$\\var{b[1]}$$\\var{b[2]}$$\\var{b[3]}$$\\var{b[4]}$$\\var{b[5]}$$\\var{b[6]}$$\\var{b[7]}$$\\var{b[8]}$$\\var{b[9]}$
\n

", "preamble": {"js": "", "css": ""}, "metadata": {"description": "

Given two distributions, calculate the measures of average and spread and make some decisions based on the results.

", "licence": "Creative Commons Attribution 4.0 International"}, "advice": "

We denote Sally as $s$ and Kate as $k$.

\n

a)

\n

We are going to start with completing the column for Sally.

\n

First, we need to find the sum of the step lengths:

\n

\\[\\begin{align}  \\sum s &= \\var{a[0]} + \\var{a[1]} + \\var{a[2]} + \\var{a[3]} + \\var{a[4]} + \\var{a[5]} + \\var{a[6]} + \\var{a[7]} + \\var{a[8]} + \\var{a[9]}   \\\\&= \\var{suma} \\text{.}
\\end{align}\\]

\n

The total number of measurements $n$ is $10$.

\n

Therefore the mean is

\n

\\[ \\begin{align} \\overline{s} &= \\frac{\\sum s}{n} \\\\[3pt]&= \\frac{\\var{suma}}{10} \\\\&= \\var{meana} \\text{.} \\end{align}\\]

\n

 

\n

The median is the middle value. We need to sort the list in order:

\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n
Sally (cm)$\\var{asort[0]}$$\\var{asort[1]}$$\\var{asort[2]}$$\\var{asort[3]}$$\\var{asort[4]}$$\\var{asort[5]}$$\\var{asort[6]}$$\\var{asort[7]}$$\\var{asort[8]}$$\\var{asort[9]}$
\n

There is an even number of responses, so there are two numbers in the middle (5th and 6th place). To find the median, we need to find the mean of these two numbers $\\var{asort[4]}$ and $\\var{asort[5]}$:

\n

\\[ \\displaystyle \\begin{align} \\frac{\\var{asort[4]} + \\var{asort[5]}}{2} &=  \\frac{\\var{asort[4] + asort[5]}}{2} \\\\&= \\var{mediana} \\text{.} \\end{align}\\]

\n

 

\n

The mode is the value that occurs the most often in the data.

\n

To find a mode, we can look at our sorted list:

\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n
Sally (cm)$\\var{asort[0]}$$\\var{asort[1]}$$\\var{asort[2]}$$\\var{asort[3]}$$\\var{asort[4]}$$\\var{asort[5]}$$\\var{asort[6]}$$\\var{asort[7]}$$\\var{asort[8]}$$\\var{asort[9]}$
\n

We notice that $\\var{modea}$ occurs the most times (3) and so $\\var{modea}$ is the mode.

\n

 

\n

The range is the difference between the highest and the lowest value in the data.

\n

To find this, we subtract the lowest value from the highest value:

\n

\\[ \\var{max(a)} - \\var{min(a)} = \\var{rangea} \\text{.}\\]

\n

 

\n

So the first column is

\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n
Sally (cm)
Mean length$\\var{meana}$
Median length$\\var{mediana}$
Modal length$\\var{modea}$
Range$\\var{rangea}$
\n

 

\n

Similarly for Kate,

\n

\\[\\begin{align}  \\sum k &= \\var{b[0]} + \\var{b[1]} + \\var{b[2]} + \\var{b[3]} + \\var{b[4]} + \\var{b[5]} + \\var{b[6]} + \\var{b[7]} + \\var{b[8]} + \\var{b[9]}   \\\\&= \\var{sumb} \\text{.}
\\end{align}\\]

\n

The total number of measurements $n$ is $10$ again.

\n

Therefore the mean is

\n

\\[ \\begin{align} \\overline{k} &= \\frac{\\sum t}{n} \\\\[3pt]&= \\frac{\\var{sumb}}{10} \\\\&= \\var{meanb} \\text{.} \\end{align}\\]

\n

 

\n

For median, we sort the list in order:

\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n
Kate (cm)$\\var{bsort[0]}$$\\var{bsort[1]}$$\\var{bsort[2]}$$\\var{bsort[3]}$$\\var{bsort[4]}$$\\var{bsort[5]}$$\\var{bsort[6]}$$\\var{bsort[7]}$$\\var{bsort[8]}$$\\var{bsort[9]}$
\n

There is an even number of responses, so there are two numbers in the middle (5th and 6th place). We find the mean of these two numbers $\\var{bsort[4]}$ and $\\var{bsort[5]}$:

\n

\\[ \\displaystyle \\begin{align} \\frac{\\var{bsort[4]} + \\var{bsort[5]}}{2} &=  \\frac{\\var{bsort[4] + bsort[5]}}{2} \\\\&= \\var{medianb} \\text{.} \\end{align}\\]

\n

 

\n

For mode, we look at our sorted list:

\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n
Kate (cm)$\\var{bsort[0]}$$\\var{bsort[1]}$$\\var{bsort[2]}$$\\var{bsort[3]}$$\\var{bsort[4]}$$\\var{bsort[5]}$$\\var{bsort[6]}$$\\var{bsort[7]}$$\\var{bsort[8]}$$\\var{bsort[9]}$
\n

We notice that $\\var{modeb}$ occurs the most times (2) and so $\\var{modeb}$ is the mode.

\n

 

\n

To find the range, we subtract the lowest value from the highest value:

\n

\\[ \\var{max(b)} - \\var{min(b)} = \\var{rangeb} \\text{.}\\]

\n

 

\n

So the complete table is\u200b

\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n
Sally (cm)Kate (cm)
Mean length$\\var{meana}$$\\var{meanb}$
Median length$\\var{mediana}$$\\var{medianb}$
Modal length$\\var{modea}$$\\var{modeb}$
Range$\\var{rangea}$$\\var{rangeb}$
\n

\n

b)

\n

Kate is the correct answer, because she has a larger range of values, therefore her step length is less consistent.

", "tags": [], "rulesets": {}, "variables": {"meana": {"group": "Ungrouped variables", "name": "meana", "description": "", "definition": "(a1 + a2 + a3 + a4 + a5+ a6 + a7 + a8 + a9 + a10)/10", "templateType": "anything"}, "bsort": {"group": "B", "name": "bsort", "description": "", "definition": "sort(b)", "templateType": "anything"}, "a2": {"group": "A", "name": "a2", "description": "", "definition": "meanab - 1 - random2", "templateType": "anything"}, "alist": {"group": "A", "name": "alist", "description": "", "definition": "[a1,a2,a3,a4,a5,a6,a7,a8,a9,a10]", "templateType": "anything"}, "meanb": {"group": "Ungrouped variables", "name": "meanb", "description": "", "definition": "(b1+b2+b3+b4+b5+b6+b7+b8+b9+b10)/10", "templateType": "anything"}, "a9": {"group": "A", "name": "a9", "description": "", "definition": "meanab + 1 + random2", "templateType": "anything"}, "sumb": {"group": "Ungrouped variables", "name": "sumb", "description": "", "definition": "sum(b)", "templateType": "anything"}, "a3": {"group": "A", "name": "a3", "description": "", "definition": "meanab - 2", "templateType": "anything"}, "b7": {"group": "B", "name": "b7", "description": "", "definition": "meanab - 2", "templateType": "anything"}, "a10": {"group": "A", "name": "a10", "description": "", "definition": "meanab + 2 + random2", "templateType": "anything"}, "meanab": {"group": "Ungrouped variables", "name": "meanab", "description": "", "definition": "random(57..64)", "templateType": "anything"}, "random": {"group": "B", "name": "random", "description": "", "definition": "random(2..10 #2)", "templateType": "anything"}, "rangea": {"group": "Ungrouped variables", "name": "rangea", "description": "", "definition": "max(a) - min(a)", "templateType": "anything"}, "a8": {"group": "A", "name": "a8", "description": "", "definition": "meanab + 1", "templateType": "anything"}, "b10": {"group": "B", "name": "b10", "description": "", "definition": "meanab + random/2", "templateType": "anything"}, "a6": {"group": "A", "name": "a6", "description": "", "definition": "meanab", "templateType": "anything"}, "asort": {"group": "A", "name": "asort", "description": "", "definition": "sort(a)", "templateType": "anything"}, "b5": {"group": "B", "name": "b5", "description": "", "definition": "meanab - 8 ", "templateType": "anything"}, "b9": {"group": "B", "name": "b9", "description": "", "definition": "meanab + random/2", "templateType": "anything"}, "b6": {"group": "B", "name": "b6", "description": "", "definition": "meanab - 6", "templateType": "anything"}, "b1": {"group": "B", "name": "b1", "description": "", "definition": "meanab - random", "templateType": "anything"}, "a1": {"group": "A", "name": "a1", "description": "", "definition": "meanab - 2 - random2", "templateType": "anything"}, "b3": {"group": "B", "name": "b3", "description": "", "definition": "meanab - 2", "templateType": "anything"}, "mediana": {"group": "Ungrouped variables", "name": "mediana", "description": "", "definition": "median(a)", "templateType": "anything"}, "rangeb": {"group": "Ungrouped variables", "name": "rangeb", "description": "", "definition": "max(b) - min(b)", "templateType": "anything"}, "modea": {"group": "Ungrouped variables", "name": "modea", "description": "", "definition": "mode(a)[0]", "templateType": "anything"}, "b": {"group": "B", "name": "b", "description": "", "definition": "shuffle(blist)", "templateType": "anything"}, "medianb": {"group": "Ungrouped variables", "name": "medianb", "description": "", "definition": "median(b)", "templateType": "anything"}, "a4": {"group": "A", "name": "a4", "description": "", "definition": "meanab", "templateType": "anything"}, "a": {"group": "A", "name": "a", "description": "", "definition": "shuffle(alist)", "templateType": "anything"}, "a5": {"group": "A", "name": "a5", "description": "", "definition": "meanab", "templateType": "anything"}, "random2": {"group": "A", "name": "random2", "description": "", "definition": "random(1..3)", "templateType": "anything"}, "b4": {"group": "B", "name": "b4", "description": "", "definition": "meanab - 10", "templateType": "anything"}, "b2": {"group": "B", "name": "b2", "description": "", "definition": "meanab ", "templateType": "anything"}, "a7": {"group": "A", "name": "a7", "description": "", "definition": "meanab + 1", "templateType": "anything"}, "blist": {"group": "B", "name": "blist", "description": "", "definition": "[b1,b2,b3,b4,b5,b6,b7,b8,b9,b10]", "templateType": "anything"}, "b8": {"group": "B", "name": "b8", "description": "", "definition": "meanab +6", "templateType": "anything"}, "modeb": {"group": "Ungrouped variables", "name": "modeb", "description": "", "definition": "mode(b)[0]", "templateType": "anything"}, "suma": {"group": "Ungrouped variables", "name": "suma", "description": "", "definition": "sum(a)", "templateType": "anything"}}, "extensions": ["stats"], "functions": {}, "parts": [{"scripts": {}, "variableReplacements": [], "prompt": "

Using the data above, fill in the following table.

\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n
Sally (cm)Kate (cm)
Mean length[[0]][[1]]
Median length[[2]][[3]]
Modal length[[4]][[5]]
Range[[6]][[7]]
\n

", "showFeedbackIcon": true, "unitTests": [], "marks": 0, "customMarkingAlgorithm": "", "variableReplacementStrategy": "originalfirst", "gaps": [{"scripts": {}, "maxValue": "meana", "correctAnswerFraction": false, "variableReplacements": [], "mustBeReduced": false, "showFeedbackIcon": true, "unitTests": [], "marks": 1, "notationStyles": ["plain", "en", "si-en"], "customMarkingAlgorithm": "", "variableReplacementStrategy": "originalfirst", "extendBaseMarkingAlgorithm": true, "minValue": "meana", "allowFractions": false, "type": "numberentry", "showCorrectAnswer": true, "correctAnswerStyle": "plain", "mustBeReducedPC": 0}, {"scripts": {}, "maxValue": "meanb", "correctAnswerFraction": false, "variableReplacements": [], "mustBeReduced": false, "showFeedbackIcon": true, "unitTests": [], "marks": 1, "notationStyles": ["plain", "en", "si-en"], "customMarkingAlgorithm": "", "variableReplacementStrategy": "originalfirst", "extendBaseMarkingAlgorithm": true, "minValue": "meanb", "allowFractions": false, "type": "numberentry", "showCorrectAnswer": true, "correctAnswerStyle": "plain", "mustBeReducedPC": 0}, {"scripts": {}, "maxValue": "mediana", "correctAnswerFraction": false, "variableReplacements": [], "mustBeReduced": false, "showFeedbackIcon": true, "unitTests": [], "marks": 1, "notationStyles": ["plain", "en", "si-en"], "customMarkingAlgorithm": "", "variableReplacementStrategy": "originalfirst", "extendBaseMarkingAlgorithm": true, "minValue": "mediana", "allowFractions": false, "type": "numberentry", "showCorrectAnswer": true, "correctAnswerStyle": "plain", "mustBeReducedPC": 0}, {"scripts": {}, "maxValue": "medianb", "correctAnswerFraction": false, "variableReplacements": [], "mustBeReduced": false, "showFeedbackIcon": true, "unitTests": [], "marks": 1, "notationStyles": ["plain", "en", "si-en"], "customMarkingAlgorithm": "", "variableReplacementStrategy": "originalfirst", "extendBaseMarkingAlgorithm": true, "minValue": "medianb", "allowFractions": false, "type": "numberentry", "showCorrectAnswer": true, "correctAnswerStyle": "plain", "mustBeReducedPC": 0}, {"scripts": {}, "maxValue": "modea", "correctAnswerFraction": false, "variableReplacements": [], "mustBeReduced": false, "showFeedbackIcon": true, "unitTests": [], "marks": 1, "notationStyles": ["plain", "en", "si-en"], "customMarkingAlgorithm": "", "variableReplacementStrategy": "originalfirst", "extendBaseMarkingAlgorithm": true, "minValue": "modea", "allowFractions": false, "type": "numberentry", "showCorrectAnswer": true, "correctAnswerStyle": "plain", "mustBeReducedPC": 0}, {"scripts": {}, "maxValue": "modeb", "correctAnswerFraction": false, "variableReplacements": [], "mustBeReduced": false, "showFeedbackIcon": true, "unitTests": [], "marks": 1, "notationStyles": ["plain", "en", "si-en"], "customMarkingAlgorithm": "", "variableReplacementStrategy": "originalfirst", "extendBaseMarkingAlgorithm": true, "minValue": "modeb", "allowFractions": false, "type": "numberentry", "showCorrectAnswer": true, "correctAnswerStyle": "plain", "mustBeReducedPC": 0}, {"scripts": {}, "maxValue": "rangea", "correctAnswerFraction": false, "variableReplacements": [], "mustBeReduced": false, "showFeedbackIcon": true, "unitTests": [], "marks": 1, "notationStyles": ["plain", "en", "si-en"], "customMarkingAlgorithm": "", "variableReplacementStrategy": "originalfirst", "extendBaseMarkingAlgorithm": true, "minValue": "rangea", "allowFractions": false, "type": "numberentry", "showCorrectAnswer": true, "correctAnswerStyle": "plain", "mustBeReducedPC": 0}, {"scripts": {}, "maxValue": "rangeb", "correctAnswerFraction": false, "variableReplacements": [], "mustBeReduced": false, "showFeedbackIcon": true, "unitTests": [], "marks": 1, "notationStyles": ["plain", "en", "si-en"], "customMarkingAlgorithm": "", "variableReplacementStrategy": "originalfirst", "extendBaseMarkingAlgorithm": true, "minValue": "rangeb", "allowFractions": false, "type": "numberentry", "showCorrectAnswer": true, "correctAnswerStyle": "plain", "mustBeReducedPC": 0}], "extendBaseMarkingAlgorithm": true, "type": "gapfill", "showCorrectAnswer": true, "sortAnswers": false}, {"maxMarks": 0, "scripts": {}, "displayType": "radiogroup", "minMarks": 0, "variableReplacements": [], "prompt": "

Is Sally or Kate most likely to have problems with the neuromuscular control of their walking?

", "showFeedbackIcon": true, "unitTests": [], "marks": 0, "customMarkingAlgorithm": "", "variableReplacementStrategy": "originalfirst", "extendBaseMarkingAlgorithm": true, "matrix": [0, "2"], "type": "1_n_2", "showCorrectAnswer": true, "choices": ["

Sally

", "

Kate

"], "shuffleChoices": false, "distractors": ["", ""], "displayColumns": 0}], "type": "question", "contributors": [{"name": "Stanislav Duris", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/1590/"}, {"name": "Lauren Frances Desoysa", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/2490/"}]}]}], "contributors": [{"name": "Stanislav Duris", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/1590/"}, {"name": "Lauren Frances Desoysa", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/2490/"}]}