Udemy
Turn what you know into an opportunity and reach millions around the world.
Learn More
Your cart is empty.
Keep shopping
Confidently Wrong — ten checks before you trust a number
New
Rating: 5.0 out of 5(2 ratings)
18 students

Confidently Wrong — ten checks before you trust a number

Ten five-minute checks that catch a model lying with its score, each one run on real data.
Last updated 11/2026
English
English

What you'll learn

  • Count the positives in a test set before reading any score off it
  • Read a confusion matrix and work out precision and recall yourself
  • Build a trivial baseline and measure the gap your model actually bought
  • Check whether claimed confidence matches what really happened
  • Perturb what cannot matter, and watch which predictions move
  • Catch leakage by asking when each value existed
  • Find duplicate rows that cross a train/test split
  • Measure the spread across seeds instead of trusting one run
  • Tell when a model is being asked about data outside its training range
  • Use resampling to separate a finding from an artefact

Course content

1 section • 10 lectures • 43m total length
  • Count the positives, before you read the score4:21

    A fraud detector scores 99.8% on 285,000 transactions and finds none of the 492 frauds in them. Before you read any score, count how many positives the test set actually holds: if they are rare, accuracy is measuring the majority class and telling you nothing about the model.

  • Quiz 1 — Count the positives
  • Read the matrix4:14

    Two settings of the same model score 99.92% and 99.93%. Underneath, one finds 93 frauds and the other 113, bought with 12 more false alarms. Read the four cells and work out precision and recall yourself, because the headline hides the trade you just made.

  • Quiz 2 — Read the matrix
  • Beat a trivial baseline3:40

    A model scoring 99.92% looks strong until you learn that predicting the majority class for every single row scores 99.83%. Build the dumbest possible baseline first. The gap between it and your model is what your work actually bought.

  • Quiz 3 — Beat a trivial baseline
  • Check that 90% means 90%4:18

    A classifier that is 97.7% accurate says it is 99.8% sure about 1,934 transactions, and 6.2% of them really are fraud. Bucket the predictions by the confidence they claimed and compare it against what happened — if the two columns do not track, the confidence is decoration.

  • Quiz 4 — Check that 90% means 90%
  • Break something that cannot matter4:12

    Multiplying every transaction amount by 100 changes nothing real and flips 9,846 predictions: recall rises to 74% while precision falls from 87% to 1.1. Change what carries no information, and the predictions that move are your answer.

  • Quiz 5 — Break something that cannot matter
  • Ask when the value existed4:11

    A planted column lifts recall twenty points overnight and outranks every genuine feature in the data. No statistic will tell you it is a leak. You have to ask when each value existed, and whether it would have been available at the moment the prediction was needed.

  • Quiz 6 — Ask when the value existed
  • Count the rows it has already seen4:21

    This dataset holds 1,081 exact duplicate rows, so a random split quietly puts 426 test rows into training as well. Scored on their own, those rows come back at 100% recall against 61.3% on rows the model has genuinely never seen.

  • Quiz 7 — Count the rows it has already seen
  • Run it again with another seed4:36

    Across ten seeds, accuracy sits flat at 99.92% while recall swings from 56.8 to 73 — a spread of more than sixteen points, with a standard deviation of 5.3. One number from one split is not a measurement. It is an anecdote with a decimal point.

  • Quiz 8 — Run it again with another seed
  • Ask if it has seen this before4:43

    Train on the smaller 95% of transaction amounts and the model never sees one above £365. Score it on amounts up to £25,000 and precision collapses from 84.5% to 4.1, while its average confidence barely moves. Outside the training range is a question it was never actually asked.

  • Quiz 9 — Ask if it has seen this before
  • Ask the data to tell the story twice4:40

    Resample the data and fit again. V14, V4 and V10 hold the top of the list run after run, while V22 appears in only two of four. What survives the resampling is what your data supports; the rest you brought with you.

  • Quiz 10 — Ask the data to tell the story twice

Requirements

  • Comfortable reading Python and pandas — you do not need to write any to follow
  • Familiarity with train/test splits and what accuracy means
  • No maths beyond arithmetic

Description

A model comes back at 99.8% on the test set. Everybody relaxes. The number is real, correctly computed, and it would survive a code review — and the model has found none of the 492 frauds in the data.

That is not a trick. It is what accuracy does when one class is rare, and it is the first of ten ways a score can be right-looking and wrong. This course is ten checks, one per lecture, five minutes each. Every one is a thing you can do in about a minute, before you trust the number in front of you.

Each lecture runs its check on the same real dataset — anonymised credit card transactions, 285,000 of them, 492 fraudulent — so you watch the failures happen rather than hear them described. You will see a 99.92% model beaten on every measure that matters by one scoring 99.83%. You will see a column that lifts recall twenty points because it should never have been in the data. You will see a model's precision fall from 84.5% to 4.1 the moment it is asked about a transaction larger than any it was trained on, while its confidence barely moves.

The checks are tool-agnostic and the reasoning is the point, but the screencasts are Python and pandas, so you can run every one of them yourself. The dataset and all ten scripts are attached to the first lecture — the same files that produced the numbers on screen, with the output they produced, so you can check that your run agrees with mine. You do not need to write any code to follow along.

By the end you will have ten specific questions to put to any model's results — your own or someone else's — and you will know what each answer rules out.

Who this course is for:

  • Anyone handed a model's score and asked whether it can be trusted
  • Analysts and engineers reviewing results they did not produce
  • People learning machine learning who can already train a model and now want to audit one
  • Anyone who has ever quoted a metric in a meeting without checking what was underneath it