Howdy, Stranger!

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

Supported by

[solved] Conditional text_input response

edited March 2016 in OpenSesame

Hi,

I am currently designing an experiment in which the participant "fishes" a certain number of fish from a pond, and then needs to decide how many from those fish he/she will keep, and how many will be released back into the pond.
What I am trying to do is to make it so that the participant cannot continue to the next trial unless the sum of the number of fishes kept and the number of fishes released equals the total number of fish caught.

Specifically here, I want to make it so that the participant can only advance from return_1 to feedback_1_! if var.correct==1.

This is the general outline of the experiment:

image

And this is the code. Each trial is divided into two inline_script items so that the focus automatically switches to the areturn text_input widget once the akeep text_input value has been entered:

http://pastebin.com/kVs0Bv5Q

Thanks in advance,
Asaf

Comments

  • edited 12:04PM

    Hi Asaf,

    What exactly is the problem or your question? Just describing your design is not enough to help us helping you.

    Well, I just take a guess here. Is it possible that your loop "Feedback_Screen" shows always, even if correct equals zero? If so, you can click on the sequence "Experimental Loop 1" and put in the run_if field of the Feedback_screen, following code:

    [correct] =1

    Does this make sense?

    Eduard

    Buy Me A Coffee

  • edited 12:04PM

    Thanks Eduard! I actually added the code itself to the post, sorry if that + the description wasn't enough.

    I resolved the issue in the end, basically what you suggested with a couple more embellishments owing to my experimental design.

    Asaf

Sign In or Register to comment.