Switcher Task
System Requirements
Minimum: 1024×768
Recommended: 1280×800
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
switcherswitcher.pbl🚀 Try Without Registration
Run this test immediately without creating an account. Data stays in your browser.
Researcher Access Benefits
To save configurations, upload data, use translations, track completion, and manage studies, please log in or register for an account.
Data Output
switch-{subnum}.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
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
| gSubNum | block | type | try | successes | rule | lastrule | curid | currentval | correct | matchColor | matchLetter | matchShape | matchLast | curcolor | curletter | curshape | targcolor | targletter | targshape | clickcolor | clickletter | clickshapetargx | targx | targy | targid | corsum | incsum | time | rt |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 999 | 0 | 0 | 1 | 0 | color | NA | 1 | 1 | 0 | 1 | 1 | 1 | NA | orange | C | circle | orange | C | circle | orange | C | circle | 1144.72 | 804.717 | 1 | 0 | 1 | 15499 | -1 |
| 999 | 0 | 0 | 2 | 0 | color | NA | 1 | 1 | 1 | 0 | 0 | 0 | 0 | orange | C | circle | orange | V | square | orange | V | square | 783.602 | 634.419 | 2 | 1 | 1 | 16296 | 1842 |
| 999 | 0 | 0 | 3 | 1 | letter | color | 2 | 2 | 1 | 0 | 0 | 0 | 0 | orange | V | square | yellow | V | plus | yellow | V | plus | 834.226 | 1073.31 | 7 | 2 | 1 | 19837 | 3541 |
| 999 | 0 | 0 | 4 | 2 | shape | letter | 7 | 3 | 1 | 0 | 0 | 0 | 0 | yellow | V | plus | skyblue | Q | plus | skyblue | Q | plus | 1268.66 | 880.858 | 4 | 3 | 1 | 21848 | 2011 |
| 999 | 0 | 0 | 5 | 3 | color | shape | 4 | 2 | 1 | 0 | 0 | 0 | 0 | skyblue | Q | plus | skyblue | T | circle | skyblue | T | circle | 935.096 | 420.736 | 3 | 4 | 1 | 23573 | 1725 |
| 999 | 0 | 0 | 6 | 4 | letter | color | 3 | 3 | 1 | 0 | 0 | 0 | 0 | skyblue | T | circle | yellow | T | star | yellow | T | star | 1067.72 | 879.026 | 8 | 5 | 1 | 25663 | 2090 |
| 999 | 0 | 0 | 7 | 5 | shape | letter | 8 | 5 | 1 | 0 | 0 | 0 | 0 | yellow | T | star | red | G | star | red | G | star | 997.633 | 796.096 | 10 | 6 | 1 | 26866 | 1203 |
| 999 | 1 | 1 | 1 | 0 | letter | NA | 1 | 3 | 1 | 0 | 0 | 0 | 0 | skyblue | X | star | bluegreen | X | circle | bluegreen | X | circle | 825.107 | 717.995 | 2 | 1 | 0 | 46623 | 4171 |
| 999 | 1 | 1 | 2 | 1 | shape | letter | 2 | 1 | 1 | 0 | 0 | 0 | 0 | bluegreen | X | circle | red | L | circle | red | L | circle | 1200.48 | 816.166 | 9 | 2 | 0 | 48726 | 2103 |
example-data-summary.csv Summary
Block-level summary statistics
| subNum | timestamp | testtype | numcues | numerr | matchlast | matchany | tooslow | waittime | perftime | medtime |
|---|---|---|---|---|---|---|---|---|---|---|
| 999 | Wed May 16 12:27:05 2018 | 1 | 15 | 0 | 0 | 0 | 6 | 7430 | 29526 | 1733 |
| 999 | Wed May 16 12:27:29 2018 | 1 | 15 | 0 | 0 | 0 | 2 | 1867 | 22642 | 1512 |
| 999 | Wed May 16 12:27:52 2018 | 1 | 15 | 0 | 0 | 0 | 1 | 5461 | 17264 | 927 |
| 999 | Wed May 16 12:28:22 2018 | 2 | 15 | 0 | 0 | 0 | 1 | 5340 | 21214 | 1520 |
| 999 | Wed May 16 12:28:52 2018 | 2 | 15 | 2 | 0 | 1 | 3 | 1879 | 27942 | 1233 |
| 999 | Wed May 16 12:29:32 2018 | 3 | 15 | 2 | 0NA0 | 2 | 7 | 5506 | 31735 | 1946 |
| 999 | Wed May 16 12:30:00 2018 | 3 | 15 | 63 | 63 | 63 | 5 | 1514 | 25890 | 1922 |
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