Howdy, Stranger!

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

Supported by

[solved] Average Response time of a voice key.

edited January 2014 in OpenSesame


I'm using the inline script "listen" published in the forum (great feature BTW) and I manage to get RT for the vocal response in the logger, but I don't no how to add an avg_rt variable that would alow me to add a feedback slide every now an then.

Any Ideas?

Thnaks in Advance



  • edited November 2013

    Hey Ezer,

    You can manually keep track of feedback variables with something like the snippet below. Obviously, you'll have to set my_response_time and is_correct yourself.

    my_response_time = 1000 # Indicates response time
    is_correct = True # Indicates whether the response is correct
    self.experiment.total_responses += 1
    if is_correct:
        self.experiment.total_correct += 1
    self.experiment.total_response_time += my_response_time
    self.experiment.acc = 100. * self.experiment.total_correct / self.experiment.total_responses
    self.experiment.avg_rt = self.experiment.total_response_time / self.experiment.total_responses
    self.experiment.accuracy = self.experiment.acc
    self.experiment.average_response_time = self.experiment.avg_rt

    Hope this helps!

    Kindest regards,

  • edited 6:58PM

    Thanks, couldn't get it to work though, I'l look into it when I have time.

    Thnaks again

Sign In or Register to comment.