Match to sample
Show a sample stimulus, then an array of choices in shuffled positions, scoring the matching choice correctly wherever it appears.
When to use it
Section titled “When to use it”Use this for match-to-sample and delayed match-to-sample designs: a sample appears alone, disappears, and an array of choices follows; the participant picks the item that matches the sample. The choice positions must vary so the answer cannot be learned as a location, the sample itself must never wander into the array, and scoring must follow the matching stimulus wherever it lands. All of that fits in one trial row.
Trial file
Section titled “Trial file”| type | content | stimFormat | stim | stimScreens | stimOrder | presTime | ISI | key | button1 |
|---|---|---|---|---|---|---|---|---|---|
| instructions | You will briefly see one picture, then four pictures. Click the one that matches. | NEXT | |||||||
| test | .jpg | sampleA;matchA;foilA1;foilA2;foilA3 | 1+4 | random(pin 1@1) | 1000 | 500 | stim2 | ||
| test | .jpg | sampleB;matchB;foilB1;foilB2;foilB3 | 1+4 | random(pin 1@1) | 1000 | 500 | stim2 | ||
| test | .jpg | sampleC;matchC;foilC1;foilC2;foilC3 | 1+4 | random(pin 1@1) | 1000 | 500 | stim2 |
type,content,stimFormat,stim,stimScreens,stimOrder,presTime,ISI,key,button1 instructions,"You will briefly see one picture, then four pictures. Click the one that matches.",,,,,,,,NEXT test,,.jpg,sampleA;matchA;foilA1;foilA2;foilA3,1+4,random(pin 1@1),1000,500,stim2, test,,.jpg,sampleB;matchB;foilB1;foilB2;foilB3,1+4,random(pin 1@1),1000,500,stim2, test,,.jpg,sampleC;matchC;foilC1;foilC2;foilC3,1+4,random(pin 1@1),1000,500,stim2,
How it works
Section titled “How it works”Each row lists five stimuli in stim: the sample first, then the correct match, then three foils. stimScreens = 1+4 splits them into two screens, the sample alone and the four choices together, and the timing columns read plainly against that structure: presTime = 1000 shows the sample for one second, and with one entry fewer than the number of screens the choice array deliberately has no duration, staying up until the response. ISI = 500 is the retention gap between sample offset and array onset.
stimOrder = random(pin 1@1) pins the first authored stimulus (the sample) to position 1, and everything unpinned shuffles across the remaining positions. The effect is exactly the paradigm’s requirement: the sample always opens the trial, and the four choices land in a fresh arrangement drawn once per session, recorded in the stimOrder_actual results column so the analysis can see where the match actually appeared.
Scoring follows the content through the shuffle: key = stim2 names the authored second stimulus (the match), and with no keyboard, buttons, or response type on the row, the choice images are clickable; the trial scores correct when the clicked image is the match, whichever array position it occupies.
Variations
Section titled “Variations”- Longer retention intervals for delayed match to sample: raise
ISIto3000or more; the structure is unchanged. - Simultaneous match to sample:
stimScreens = 5with astimPoslayout placing the sample centrally above the choices, keeping the same pin and scoring. - More or fewer choices: adjust the list and the second screen count (
1+6with five foils), leaving the pin andkey = stim2untouched. - A response deadline:
responseWindow = 4000recordstimeoutand moves on when no choice is made. - Sample also floating: drop the pin entirely and every stimulus shuffles, or pin the match instead (
random(pin 2@3)) to fix where the answer appears while the rest shuffle.