Stop Signal Task Delay

Hi Everyone!!

I’m trying to program a Stop Signal Task, where the stop signal is a sound (.wav file), which has to be played after a variable delay from the onset of the trial. What I wanted to do is to adjust this delay depending of the participant responses . In this way, when the participant is able to withhold the response in the first stop trial, the time of delay increased (by 25 ms.), in order to be harder in the next stop trial. If the participant is unable to withhold the response, the delay has to be decreased (by 25 ms too) in order to be easier on the next trial.

I tried to put this piece of code in a code component, where I wanted to increase or decrease the stop signal delay as I said. My main problem is when the participant response is incorrect, the delay decreases as I wanted, but when the response is correct (which is a None response), the delay is decreasing as well.

I put this code in the begin experiment tab:

foodS = 0
nofoodS = 0
ssd1 = 0.25
ssd2 = 0.25


And then I put this code in the begin routine tab:

if Type == 'food' and Conditions == 'noGo':
    thisExp.addData('SSD', ssd1) #registra al fitxer.csv
    foodS = foodS + 1
    if foodS > 1:
        if Type == 'food' and Conditions == 'noGo' and Response == corrAns:
            ssd1 = ssd1 + 0.025
            thisExp.addData('SSD', ssd1) #registra al fitxer.csv
        if Type == 'food' and Conditions == 'noGo' and Response != corrAns:
            ssd1 = ssd1 - 0.025
            thisExp.addData('SSD', ssd1) #registra al fitxer.csv

if Type == 'nofood' and Conditions == 'noGo':
    thisExp.addData('SSD', ssd2) #registra al fitxer.csv
    nofoodS = nofoodS + 1
    if nofoodS > 1:
        if Type == 'nofood' and Conditions == 'noGo' and Response == corrAns:
            ssd2 = ssd2 + 0.025
            thisExp.addData('SSD', ssd2) #registra al fitxer.csv
        if Type == 'nofood' and Conditions == 'noGo' and Response != corrAns:
            ssd2 = ssd2 - 0.025
            thisExp.addData('SSD', ssd2) #registra al fitxer.csv

Any suggestions to fix that?..
Thanks a lot in advance.

I attach my files:
Condicions.xlsx (19.8 KB) SST_pDelay.psyexp (33.9 KB)

Hi @Marc_B, did you resolve this problem? If yes, would you mind sharing how you resolve it?

Hey everyone,

I am currently designing a very similar task and stumbled upon the exact same issue. Does maybe anyone today has an idea on how to resolve this?

Thank you!