Switcher Task

Executive Function Duration: ~5 minutes
Switcher Task screenshot

System Requirements

🖥️
Screen Size:
Minimum: 1024×768
Recommended: 1280×800
⌨️
Keyboard required
🖱️
Mouse required (touchpad OK)
⚠️
Color discrimination required
May be challenging for colorblind participants

Description

The PEBL Switcher task: A novel task to measure cognitive flexibility and rule switching.

About This Test

A cognitive flexibility task where participants match colored letters displayed in different shapes based on shifting rules. Ten target stimuli appear on screen, each combining one of five colors (orange, skyblue, bluegreen, yellow, red), one of five letters (A-E), and one of five shapes (circle, square, plus, ellipse, star). On each trial, participants must click the target that matches the current stimulus according to the active rule (color, letter, or shape). The task includes practice followed by three test types: (1) consistent 2-rule switching (alternating between two rules), (2) consistent 3-rule switching (cycling through three rules in fixed order), and (3) random 3-rule switching (rules change unpredictably). Measures cognitive flexibility, rule learning, and switching costs.

Test Details

Test ID:
switcher
Main File:
switcher.pbl
Parameters:
3 configurable parameters
Languages:
Chinese German English Spanish French Italian Dutch Portuguese

🚀 Try Without Registration

Run this test immediately without creating an account. Data stays in your browser.

Data Output

Output File:
switch-{subnum}.csv
Format:
CSV

Data Columns

Column Name Description
gSubNum Participant ID
block Block number
type Test type: 0=practice, 1=consistent 2-rule, 2=consistent 3-rule, 3=random 3-rule
try Attempt number within block
successes Cumulative successes in block
rule Current matching rule (color, letter, shape, or NA)
lastrule Previous matching rule
curid Current stimulus ID
currentval Current value
correct Trial accuracy: 1=correct, 0=incorrect
matchColor Clicked color matched current stimulus (1/0)
matchLetter Clicked letter matched current stimulus (1/0)
matchShape Clicked shape matched current stimulus (1/0)
matchLast Error matched previous rule dimension (1/0)
curcolor Current stimulus color
curletter Current stimulus letter
curshape Current stimulus shape
targcolor Correct target color
targletter Correct target letter
targshape Correct target shape
clickcolor Clicked target color
clickletter Clicked target letter
clickshape Clicked target shape
targx Target X position
targy Target Y position
targid Target ID
corsum Cumulative correct count
incsum Cumulative incorrect count
time Absolute time in milliseconds
rt Response time in milliseconds

Scoring and Interpretation

Primary measures:

Accuracy: Error rate (numerr / numcues) for each test type.

Switch cost: Compare median RT between consistent and random 3-rule conditions - higher RT in random indicates switching cost.

Perseveration: matchlast errors indicate difficulty inhibiting previous rule.

Efficiency: Lower median RT with maintained accuracy indicates better cognitive flexibility.

Compare performance across test types (1-3) to assess rule learning and switching ability.

Example Data

example-data.csv Primary

Trial-by-trial data with detailed response information

gSubNumblocktypetrysuccessesrulelastrulecuridcurrentvalcorrectmatchColormatchLettermatchShapematchLastcurcolorcurlettercurshapetargcolortarglettertargshapeclickcolorclickletterclickshapetargxtargxtargytargidcorsumincsumtimert
9990010colorNA110111NAorangeCcircleorangeCcircleorangeCcircle1144.72804.71710115499-1
9990020colorNA1110000orangeCcircleorangeVsquareorangeVsquare783.602634.419211162961842
9990031lettercolor2210000orangeVsquareyellowVplusyellowVplus834.2261073.31721198373541
9990042shapeletter7310000yellowVplusskyblueQplusskyblueQplus1268.66880.858431218482011
9990053colorshape4210000skyblueQplusskyblueTcircleskyblueTcircle935.096420.736341235731725
9990064lettercolor3310000skyblueTcircleyellowTstaryellowTstar1067.72879.026851256632090
9990075shapeletter8510000yellowTstarredGstarredGstar997.633796.0961061268661203
9991110letterNA1310000skyblueXstarbluegreenXcirclebluegreenXcircle825.107717.995210466234171
9991121shapeletter2110000bluegreenXcircleredLcircleredLcircle1200.48816.166920487262103

View full file (180 rows) →

example-data-summary.csv Summary

Block-level summary statistics

subNumtimestamptesttypenumcuesnumerrmatchlastmatchanytooslowwaittimeperftimemedtime
999Wed May 16 12:27:05 201811500067430295261733
999Wed May 16 12:27:29 201811500021867226421512
999Wed May 16 12:27:52 20181150001546117264927
999Wed May 16 12:28:22 201821500015340212141520
999Wed May 16 12:28:52 201821520131879279421233
999Wed May 16 12:29:32 201831520NA0275506317351946
999Wed May 16 12:30:00 201831563636351514258901922

Sample data showing typical output format. Actual values will vary by participant.

About This Test

The PEBL Switcher task: A novel task to measure cognitive flexibility and rule switching.

Category: Executive Function
Estimated Duration: 5 minutes
Available Translations: 8 languages

Documentation Sources:
Test description file, Test implementation, Parameter schema

Documentation Status: Complete