// Numbas version: finer_feedback_settings {"name": "Calculate CTR", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"name": "Calculate CTR", "tags": [], "metadata": {"description": "

Calculate CTR given number of clicks and number of impressions served.

\n

percentage CTR is 0.5, 1, 1.5 or 2%. Number of impressions is randomised.

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "
\n
\n
\n

During a digital media campaign {separateThousands(imps,\",\")} impressions were delivered, and {separateThousands(clickers,\",\")} people clicked on the ad.

\n
\n
\n
", "advice": "

click through rate (CTR) = the proportion of viewers who clicked the ad out of all the viewers = $\\frac{\\var{separateThousands(clickers,\",\")}}{\\var{separateThousands(imps,\",\")}}=\\var{ctr/100} = \\var{ctr}\\%$

", "rulesets": {}, "extensions": [], "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"ctr": {"name": "ctr", "group": "Ungrouped variables", "definition": "random(0.5,1,1.5,2)", "description": "", "templateType": "anything", "can_override": false}, "imps": {"name": "imps", "group": "Ungrouped variables", "definition": "random(1..5)*100000", "description": "", "templateType": "anything", "can_override": false}, "clickers": {"name": "clickers", "group": "Ungrouped variables", "definition": "imps*ctr/100", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["ctr", "imps", "clickers"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "gapfill", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

What was the percentage click through rate (CTR)?

\n

CTR = [[0]]%

", "gaps": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "ctr", "maxValue": "ctr", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always", "type": "question", "contributors": [{"name": "Susan McGlynn", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/2148/"}, {"name": "Merryn Horrocks", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/4052/"}], "resources": []}]}], "contributors": [{"name": "Susan McGlynn", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/2148/"}, {"name": "Merryn Horrocks", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/4052/"}]}