Six detectors on the survey, each with one mistake that makes it flag the wrong rows: the weight used as a feature, features of different scales given to LOF, contamination set from the wrong table, duplicates fitted twice, an id column read as a number and learned from, and ECOD scored chunk by chunk. Each check starts red.
For each one you predict what the detector flags, run it, trace the line that makes the difference, fix it, and say in one sentence what the mistake was. None of them raises an error: a detector with a mistake still returns a list of rows, and only the check tells you it is the wrong list. The companion has each fix and why it works.
What you do
Section titled “What you do”- A detector that flags the wrong rows: six bugs to find and fix
Its notebooks
Section titled “Its notebooks”- 85_debugging_drill.pyDebugging drill: a detector that flags the wrong rowsRead itCompanion · 6 exercises
The notebooks are in your course folder; here you can read them without running anything. For reference in any module: primer: from r to python and primer: survey sampling in one page and glossary.