// Numbas version: exam_results_page_options {"name": "Interpret logistic regression output from Minitab", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"variable_groups": [], "variables": {"tol": {"templateType": "anything", "group": "Ungrouped variables", "definition": "0.001", "description": "", "name": "tol"}, "r1": {"templateType": "anything", "group": "Ungrouped variables", "definition": "ansa+ansb*thismuch/1000", "description": "", "name": "r1"}, "seb": {"templateType": "anything", "group": "Ungrouped variables", "definition": "random(0.04..1.2#0.000001)", "description": "", "name": "seb"}, "sea": {"templateType": "anything", "group": "Ungrouped variables", "definition": "round((t*v1+(100-t)*v2)+0.000001)/100", "description": "", "name": "sea"}, "ansa": {"templateType": "anything", "group": "Ungrouped variables", "definition": "precround(-2.24*sea,3)", "description": "", "name": "ansa"}, "t": {"templateType": "anything", "group": "Ungrouped variables", "definition": "random(0..100)", "description": "", "name": "t"}, "tol1": {"templateType": "anything", "group": "Ungrouped variables", "definition": "0.01", "description": "", "name": "tol1"}, "thismuch": {"templateType": "anything", "group": "Ungrouped variables", "definition": "random(15000..35000#1000)", "description": "", "name": "thismuch"}, "v2": {"templateType": "anything", "group": "Ungrouped variables", "definition": "seb*thismuch/1000+0.9", "description": "", "name": "v2"}, "v1": {"templateType": "anything", "group": "Ungrouped variables", "definition": "seb*thismuch/1000-0.9", "description": "", "name": "v1"}, "prob1": {"templateType": "anything", "group": "Ungrouped variables", "definition": "precround(e^(r1)/(1+e^r1),2)", "description": "", "name": "prob1"}, "ansb": {"templateType": "anything", "group": "Ungrouped variables", "definition": "precround(2.25*seb,3)", "description": "", "name": "ansb"}}, "ungrouped_variables": ["seb", "r1", "tol1", "v1", "v2", "t", "tol", "ansa", "ansb", "thismuch", "sea", "prob1"], "question_groups": [{"pickingStrategy": "all-ordered", "questions": [], "name": "", "pickQuestions": 0}], "name": "Interpret logistic regression output from Minitab", "functions": {}, "showQuestionGroupNames": false, "parts": [{"scripts": {}, "gaps": [{"showCorrectAnswer": true, "allowFractions": false, "scripts": {}, "type": "numberentry", "maxValue": "ansa+tol", "minValue": "ansa-tol", "correctAnswerFraction": false, "marks": 1, "showPrecisionHint": false}, {"showCorrectAnswer": true, "allowFractions": false, "scripts": {}, "type": "numberentry", "maxValue": "ansb+tol", "minValue": "ansb-tol", "correctAnswerFraction": false, "marks": 1, "showPrecisionHint": false}], "type": "gapfill", "prompt": "

Find $A$ and $B$ each to 3 decimal places:

\n

$A=\\;$[[0]]     $B=\\;$[[1]]

", "showCorrectAnswer": true, "marks": 0}, {"scripts": {}, "gaps": [{"showCorrectAnswer": true, "allowFractions": false, "scripts": {}, "type": "numberentry", "maxValue": "prob1+tol1", "minValue": "prob1-tol1", "correctAnswerFraction": false, "marks": 1, "showPrecisionHint": false}], "type": "gapfill", "prompt": "

Find the probability that an employee with an annual salary of £{thismuch} will be obese.

\n

Enter your answer to two decimal places.

\n

Probability = [[0]]

", "showCorrectAnswer": true, "marks": 0}], "statement": "

It is claimed that there is a relationship between job type and obesity, with employees in more highly-paid, senior roles being more likely to be overweight than those in other roles.

\n

You are an analyst working for a large company and have been given the task to see if this is the case at your workplace. 

\n

You randomly sample 15 employees and record their annual salary ($X$, in thousands of pounds) and whether or not they are obese (have a body mass index of more than 30: $Y=1$  if yes, $Y=0$ if no).

\n

A logistic regression was performed in Minitab, with the following (edited) output shown below:

\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
\n

\n
\n

\n
\n

\n
\n

Odds

\n
\n

95% CI

\n
\n

Predictor

\n
\n

Coef

\n
\n

SE Coef

\n
\n

Z

\n
\n

P

\n
\n

Ratio

\n
\n

Lower

\n
\n

Upper

\n

Constant

\n
\n

$A$

\n
\n

{sea}

\n
\n

-2.24

\n
\n

0.025

\n
\n

\n
\n

\n
\n

\n
\n

$x$

\n
\n

$B$

\n
\n

{seb}

\n
\n

2.25

\n
\n

0.025

\n
\n

1.18

\n
\n

1.02

\n
\n

1.37

\n
", "tags": ["ACE2013", "checked2015"], "rulesets": {}, "preamble": {"css": ".minitab {\n font-family: 'Courier', monospace;\n}", "js": ""}, "type": "question", "metadata": {"notes": "

09/02/2014:

\n

Based on an i-assess question. First draft finished.

", "licence": "Creative Commons Attribution 4.0 International", "description": "

Interpreting the minitab output from a logistic regression model of salary against obesity as measured by BMI.

"}, "variablesTest": {"condition": "", "maxRuns": 100}, "advice": "

a)

\n

A is given by  A = -2.24 x  SE Coef (A) = -2.24 x {sea} = {ansa} .

\n

B is given by  B =  2.25 x  SE Coef (B) =  2.25 x {seb} = {ansb} .

\n

Both to 3 decimal places.

\n

b)

\n

The probability is given by:

\n

\\[\\begin{align}P(Y=1 | X=\\var{thismuch})&=\\frac{e^{A+B\\times\\var{thismuch/1000}}}{1+e^{A+B\\times\\var{thismuch/1000}}}\\\\&=\\frac{e^{\\var{r1}}}{1+e^{\\var{r1}}}=\\var{prob1}\\end{align}\\]

\n

to 2 decimal places.

\n

", "contributors": [{"name": "Newcastle University Mathematics and Statistics", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/697/"}]}]}], "contributors": [{"name": "Newcastle University Mathematics and Statistics", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/697/"}]}