quizOpt1 = {
const scens=["Diagnosis: depressed / anxious / control", "Agreement on a 1–5 Likert scale", "Temperature in degrees Celsius", "Reaction time in milliseconds", "Handedness: left / right / mixed", "Highest education: GCSE / A-level / degree", "Number of errors on a task"];
const ans=["Nominal", "Ordinal", "Interval", "Ratio", "Nominal", "Ordinal", "Ratio"];
const why=["Unordered labels — count them or take a mode, but they can't be ranked or averaged.", "Ordered categories, but the spacing isn't guaranteed equal — the median is the natural centre.", "Equal spacing but no true zero (0 °C isn't 'no temperature') — mean/SD fine, ratios aren't.", "Equal spacing and a true zero (0 ms = no time) — mean, SD and ratios all valid.", "Unordered labels — mode only. 'Average handedness' means nothing.", "A clear rank, but the gaps between qualifications aren't equal units — median, not mean.", "A count with a true zero (0 errors = none) and equal units — everything valid."];
const opts=["Nominal", "Ordinal", "Interval", "Ratio"];
const wrap=document.createElement("div");
scens.forEach((scen,i)=>{
const block=document.createElement("div"); block.style.cssText="margin:0 0 1rem 0";
const q=document.createElement("div"); q.style.cssText="font-weight:600;margin-bottom:.35rem"; q.textContent=(i+1)+". "+scen;
const row=document.createElement("div"); row.style.cssText="display:flex;gap:8px;flex-wrap:wrap;margin-bottom:.3rem";
const fb=document.createElement("div"); fb.style.cssText="font-size:14px;min-height:1.2rem;color:#94a3b8"; fb.textContent="Click an answer to check.";
opts.forEach(opt=>{
const b=document.createElement("button"); b.textContent=opt;
b.style.cssText="padding:5px 11px;border:1px solid #cbd5e1;border-radius:6px;background:#fff;cursor:pointer;font-size:14px";
b.onmouseenter=()=>b.style.background="#f1f5f9"; b.onmouseleave=()=>b.style.background="#fff";
b.onclick=()=>{ const ok=opt===ans[i];
fb.innerHTML=`<b style="color:${ok?'#1E7A34':'#c0392b'}">${ok?'✓ '+ans[i]:'✗ Not quite — '+ans[i]}.</b> <span style="color:#334">${why[i]}</span>`; };
row.appendChild(b);
});
block.append(q,row,fb); wrap.appendChild(block);
});
return wrap;
}What Kind of Data Is This? (Levels of Measurement)
Info sheet · Statistics for Psychology & Neuroscience
Warning✎ Editing notes — to do / to check
Working notes for the author — not shown to students once collapsed; remove before publishing.
What you’ll get from this sheet
Not all numbers are created equal. By the end you should be able to:
- Tell the four levels of measurement apart.
- Say which summaries and tests each one permits.
Four levels, in increasing richness: nominal (labels, no order) → ordinal (ordered, uneven spacing) → interval (equal spacing, no true zero) → ratio (equal spacing and a true zero). The level decides what’s meaningful: mode for nominal, median for ordinal, mean/SD for interval and ratio.
The four levels
- Categorical (nominal) — labels with no order: diagnosis (depressed / anxious / control), stimulus type, handedness. You can count them, but “average diagnosis” is meaningless.
- Ordinal — an order, but unequal or unknown spacing: Likert ratings (1–5), education level, disease stage. The categories rank, but the gap from “agree” to “strongly agree” needn’t equal the gap from “neutral” to “agree.”
- Interval — equal spacing, no true zero: temperature in °C, many standardised test scores. Differences are meaningful; ratios aren’t (20 °C isn’t “twice as hot” as 10 °C).
- Ratio — equal spacing and a meaningful zero: reaction time, firing rate, error counts. Ratios finally make sense — a 400 ms response really is twice as slow as a 200 ms one.
The practical payoff: the level constrains your options. A mean and SD suit interval and ratio data; a median suits ordinal data; a mode or a count is all that’s meaningful for categorical data.
Quiz: what level is it?
Test yourself — expand the box and answer each question.
NoteQuiz
Answer each question — the feedback appears beneath it.
See it in code
R encodes the level with the variable’s type — an unordered factor, an ordered factor, or plain numeric:
diagnosis = categorical({'dep','anx','control','anx'}); % nominal
likert = categorical({'agree','neutral','strongly_agree'}, ...
{'disagree','neutral','agree','strongly_agree'}, 'Ordinal', true); % ordinal
rt = [320 410 285 500]; % ratio
summary(diagnosis) % counts / mode — nominal
median(double(likert)) % median of the ordinal ranks
mean(rt), std(rt) % mean & SD — ratioThe R and Python tabs run live; MATLAB is a static reference.
TipCheck your understanding
Why is it wrong to report the mean of a 1–5 Likert item, strictly speaking?
Because a Likert scale is ordinal: the responses are ordered, but the psychological distance between “disagree” and “neutral” isn’t guaranteed to equal the distance between “agree” and “strongly agree.” A mean assumes equal‑sized units (interval data), so averaging ranks can mislead. The strictly‑correct centre is the median. (In practice people often average Likert items anyway — especially when several are summed into a scale — but it’s a shortcut worth knowing you’re taking.)
Don’t let a variable’s appearance fool you: numbers can be nominal (participant ID, jersey number) and words can be ordinal (disease stage). The classic trap is treating ordinal data as interval and averaging it. And watch the true‑zero test for interval vs ratio — Celsius and IQ have no meaningful zero, so “twice as hot” or “twice as smart” are nonsense, whereas reaction time and counts do.
Where this shows up next
The level of measurement decides which descriptive statistics and which tests are legitimate — the very next sheet, Describing Data, puts them to work. See Chapter (Foundations).