CPSKIT / BLOG

How the review threshold changes what a double-click check flags

The double-click check on CPSKit asks you to pick a review threshold — 40, 80 or 120 milliseconds — before you start. That number is not a pass/fail line for a broken switch. It is simply the cutoff below which the tool counts the gap between two adjacent button presses as “short.” Choose a larger threshold and more of your intervals get flagged; choose a smaller one and fewer do. This post shows the exact effect, with example inputs you can run through the same function the tool uses.

What the check actually measures

Each time you press the primary button, the browser records a timestamp. The check looks at the gap between each press and the one before it, and counts how many of those gaps fall below your chosen threshold. Nothing more. It never decides why a gap was short — a bouncing switch and a deliberately fast click produce the same number.

The same clicks, three thresholds

Below are four stated interval sets — the millisecond gaps between consecutive presses. These are example inputs chosen to illustrate the filter, not measurements from any real device. The “flagged” columns are the actual output of the tool’s shortIntervals function at each threshold:

Example press intervals (ms)40 ms80 ms120 ms
140, 155, 160, 148, 152, 145 — even, deliberate0 / 60 / 60 / 6
150, 55, 160, 145, 158 — one brief pair0 / 51 / 51 / 5
150, 45, 160, 70, 155 — two brief pairs0 / 52 / 52 / 5
90, 85, 78, 92, 88, 95 — fast, intentional0 / 61 / 66 / 6

The takeaways

  • The threshold moves the line, not the clicks. The “two brief pairs” row has a 45 ms and a 70 ms gap. At a 40 ms cutoff neither is short enough to flag (0 / 5); raise the cutoff to 80 ms and both cross the line at once (2 / 5). The clicks never changed — only the threshold did.
  • A high threshold can flag ordinary fast clicking. The last row is steady 78–95 ms clicking with no defect at all. At 120 ms it flags every single interval — a clean example of why a large threshold on its own is not evidence of chatter.
  • One flagged interval is not a diagnosis. That is why the tool reports “observed once” until the same pattern repeats across separate runs.

Reproduce it yourself

The counts above are deterministic. Given the same intervals and threshold, the function returns the same result every time — here is the logic it uses:

// build timestamps from the gaps, then count gaps below the threshold
const stamps = intervals.reduce((s, d) => [...s, s.at(-1) + d], [0]);
const flagged = stamps
  .slice(1)
  .map((t, i) => t - stamps[i])
  .filter((gap) => gap >= 0 && gap < threshold).length;

Run your own presses in the double-click check at each threshold and compare. If short intervals reproduce across thresholds and across separate runs, that is worth noting — see why a single click becomes two for what to do next.

These worked examples use stated inputs to demonstrate the filter. They are not measurements from a specific mouse, and a small set of intervals describes only the clicks in that set. A browser check documents timing; it does not certify hardware condition. These figures are published in the open double-click input behavior dataset.

← All posts

Your recent tests

Up to 30 runs on this browser. Clearing site data also removes them.

No completed or interrupted runs saved yet. Start with a quick test.