Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Supported by

problem in an approach-avoid-inhibition experiment

Hi All,
I'm working on an experiment that involves approach, avoid and inhibition trials in response to emotional stimuli (negative, positive and neutral images). On some trials the participants have to press an "approach" key whenever a vertical line appears in the middle of the screen (and within the emotional image). Whenever the participant presses the approach key the image becomes larger as if moving towards them. On other trials, participants have to press an "avoid" key in response to a horizontal line appearing within the image. After pressing the avoid key, the image becomes smaller as if moving away from the participants. Additional, on some trials a "beep" sound appears alongside these target stimuli, indicating for participants not to press any key. The stop-signal beep always appears within a changing interval after the target stimuli (image + vertical/horizontal line).
At the moment I'm facing two problems:

  1. In Opensesame's results excel file there are two (or even more) rows indicating errors, for example a row labeled "correct" and another labeled "correct_keyboard_response_1_1". Unfortunately, on some inhibitory trials, they show different results (i.e. one of them considers the response as correct and the other consider it as an error), so that I don't know which row to refer to. Since the interval between the appearance of the target stimuli and the stop-signal also depends on whether the participant made a mistake or not on the previous inhibitory trial, it is crucial to realize whether the program consider some trials as correct or as errors (for example on an inhibitory trial when the participant did press a key).

  2. The sequence of the inhibitory trials is; target (sketchpad) -> sampler -> keyboard response -> 3 other sketchpads (with the image enlarged/diminished/same size) from which only one appears in accordance to the participant response (approach/avoid/no response). However, at the moment, on the inhibitory trials, if a participant presses any key before **the appearance of the stop signal, the image does not become larger or smaller (as it should), but only if the participant presses the key **after the appearance of the stop signal. I can;t find a way to make the image grow or diminish even if the participant pressed a button before the stop-signal appears.

I'd be grateful for your assistance as I couldn't find a way to solve these issues.
I could upload the experiment if it could be of help.
Sorry for this long description, hope I managed to properly explain things.
Thank you for your help!


  • Hi Marina,

    However, at the moment, on the inhibitory trials, if a participant presses any key before **the appearance of the stop signal, the image does not become larger or smaller (as it should), but only if the participant presses the key **after the appearance of the stop signal.

    I suppose you present the second image contingent on a correct response? So, in no_response trials, the correct response is no response, not one of the response keys, right? If you specify that on no_responsetrials the second image should be shown depending on whether participants press approach or avoid, regardless of correctness, you should be able to see it. Or do I misunderstand the question?

    for example a row labeled "correct" and another labeled "correct_keyboard_response_1_1

    Without seeing your experiment, it can be tricky to say what is going on exactly. The variable correct is created by Opensesame automatically by comparing the given response to the variable correct_response. The other one, is a response to a particular keyboard item, I think, but again, I would have to see your experiment to be sure. Generally, the variable var.correct should be the one to use, that is if you set up your experiment accordingly.

    If you like you can upload the experiment, and I'll have a look at it.


  • Hi Eduard,

    Thank you for helping out, the experiment file it uploaded here as it's too large to share on the forum;

    Yes, you understood correctly. In all trials, whenever the participant presses a key the image should grow (if they pressed "b"") or reduce (if they presses "o"), regardless if the response is correct or not or whether there was a stop-signal or not. At the moment, on stop-signal trials, if the participant presses a key before the stop-signal appeared, the image does not grow or reduce as it should. What should be happening is that even if the participant pressed a key before the stop signal appeared, the image would grow/reduce, the stop-signal will still be heard (even if a key was already pressed), and the response would be coded as error.
    In the experimental file, you can see the "target enlarged/reduced/no change" sketchpad items at the end of each block. one of them is always presented as the outcome of the participant's response or lack of response. The different "Go" blocks are fine. the problem is in the inhibitory blocks, which are named "NegPic", "NeutPic"and "PosPic". on these blocks, if you press a key during the interval when the "target_0" sketchpad item appears, the image does not grow or diminish, but only if you press a key during the "target_1"sketchpad item which appears after the stop-signal. On the "Stop" block, which is part of the practice phase, I tried omitting the "target_1" item but it did not solve the issue.

    Regarding the second issue, I attached an output excel file for example, where only the practice trials were preformed. As you can see, there are two "correct" columns on columns H and I. However, on some of the inhibition trials, one of them registers a correct response while the other shows an error (for example on lines H6 and I6, or H8 and I8). I believe that has to do with the first issue as well, as this issue doesn't happen on Go trials, where both columns seems to be aligned.

    I hope all of this is clear.
    Once again, thank you very much for your kind assistance.

  • Hi Marina,

    Regarding your first issue, if you set the duration of the sampler to 0, you get the corresponding action for each keypress. (the tone is still presented for 300 ms). Aside of that, I recommend you use the same (linked copy) of your keyboard item throughout your experiment, this will make it easier to analyze your results. Furthermore, there is no need to specify None as possible response, it will work even without. Finally, an expression like [SSD] or [response] in a Duration field is not valid code. I don't think you can do something like that with the Items, you probably would have to do some inline scripting. Anyway, you should delete the 2nd part (leave only [SSD]).

    Regarding the second issue, just look at the columns response, correct_responseand correct. These are the most important ones. If the first two match, the third should be 1, if they don't match, they should be 0 (and when I tried your experiment, with the changes I suggested above, it does make perfect sense)

    Hope this makes sense!


  • Hi Eduard,

    Thank you for the useful advises. I made the corrections as you suggested.
    However, the image still does not grow/diminish when you press a key before the stop-signal appears
    in stop trials (even after setting the sampler duration to 0 and leaving only [SSD] as the target duration).
    Any other idea of what can cause this problem?

    Thank you,


  • Really? It does happen when I do it. I have no idea what could be the reason for that. Btw. I used the legacy backend. In case that matters.


  • Very strange. Yeah I tried changing to legacy too but it's still doesn't solve it (although the experiment does run more smoothly now!). I uploaded the adjusted file to the google docs folder in case you will be willing taking another look and see if what I did works at yours and whether I missed anything.

    Thank you !

Sign In or Register to comment.