Skip to content

Adaptive staircase

Home in on a participant’s detection threshold by making trials harder after correct answers and easier after misses.

Use this when the interesting quantity is a threshold (the faintest contrast, the shortest duration, the smallest difference a participant can still detect) rather than accuracy at one fixed difficulty. Presenting every difficulty level equally often wastes most trials far above or below the threshold, where performance is at ceiling or at chance and carries little information. An adaptive procedure concentrates trials where the participant’s limit actually lies, giving a usable estimate from far fewer trials. If you need a full psychometric function across the whole difficulty range, or difficulty cannot be expressed as an ordered set of rows, use a fixed design with random presentation instead.

typetitlecontentstimFormatstim1keyboardkeyresponseWindowstaircasebutton1
instructionsSpot the ringA faint ring will flash on each trial. Press SPACE as soon as you see it. If you saw nothing, wait and the next trial will start by itself.NEXT
test.pngring_c90spacespace1500detect: start 2 correct 2 incorrect 1 reversals 6 trials 30
test.pngring_c70spacespace1500detect
test.pngring_c50spacespace1500detect
test.pngring_c35spacespace1500detect
test.pngring_c25spacespace1500detect
test.pngring_c15spacespace1500detect
test.pngring_c10spacespace1500detect
instructionsDoneThreshold block complete. Press NEXT to continue.NEXT

The seven rows sharing the staircase ID detect form one contiguous block, ordered easiest to hardest: row position is the difficulty level, here ring images of decreasing contrast (basenames in stim1, the .png extension supplied by stimFormat). The parameters after the colon are read only from the first row of the block; the later rows just repeat the bare ID. Keep the ID to a single plain word, because parameter names are matched anywhere in the cell and an ID like my up 2 test would silently set a parameter.

Each trial is scored through the ordinary response machinery, which is what drives the steps. keyboard accepts only space, key marks that press correct, and the numeric responseWindow of 1500 records a timeout response when nothing is pressed in time, which fails the key check and counts as incorrect. With correct 2 and incorrect 1 the block runs a classic 2-down 1-up rule: two accumulated correct answers move one row down (harder), a single miss moves one row up (easier), and this rule converges near 71 per cent correct detection. start 2 begins at the second level rather than the hardest or easiest extreme. Until a move triggers, the same row simply repeats, and the counters reset after every move.

The staircase ends after 6 reversals, or once more than 30 trials have run, or when a step leaves the block’s row range. Its final trial is flagged in the staircaseResult results column, and the participant continues with the first trial after the block, here the closing instructions row. That row is not decoration: if nothing follows the staircase, the run stops with the error “Could not find the last trial of this staircase group”. Two side effects worth knowing: rows carrying a staircase value are exempt from shuffling, and staircase repetitions do not advance the sequential trial counter, so a progress bar stalls during the block.

  • Interleave two independent staircases by giving both the same group number in staircase (for example one starting easy and one starting hard); at each step a random unfinished member of the group runs next.
  • Let good performers descend faster before the first reversal with a boost parameter in staircase, for example boost 2.
  • Shift the convergence point by changing the correct count in staircase: correct 3 incorrect 1 tracks a higher accuracy level than 2-down 1-up.
  • Refine the difficulty grid by inserting more rows with the same staircase ID; the block is defined by the contiguous rows that share it, and steps move through whatever levels you provide.