Howdy, Stranger!

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

Supported by

Counter Variable

Hi everyone,
i'm stuck on implementing a counter variable in my experiment. I want to count correct feedback in a probabilistic choice task to provide money based on the amount of positive feedback received. Therefore, i have a trial loop+sequence in which a choice display is shown, and within, another loop and sequence for the feedback screen.
At the beginning of the experiment, i set the counter to value 0.
Within in feedback sequence i then wrote a script that should update the counter whenever another variable in the choice phase has the value "green", which is based on the exp.response variable:
if exp.feedbackvariable == 'green':
exp.counter += 1
During the experiment i can see my counter variable in the inspector, however, it remains 0 regardless of correct/incorrect feedback.
I'm thankful for any kinds of suggestions.
Btw: i'm using win10, OpenSesame 3.2.1 with Python 2.7.13

Thanks in advance,


  • try this:

    if exp.feedbackvariable == 'green':
        var.counter=var.counter +1

    I am not sure. But maybe it helps?

Sign In or Register to comment.