Howdy, Stranger!

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

Supported by

Rating own written sentences

Dear OpenSesame Community,
I would like to create a "unique" sentences completion task. In the experiment, the participants first complete sentences (freely, like in "text_input" form) and after completing all the sentences in the experiment, I want them to review what they wrote and give it a grade with checkbox form, one sentence at a time. Does anyone have any idea how can I create such experiment using minimum programming? Thanks :smile:

Comments

  • Hi,

    I think this will inevitably involve a small degree of programming. You have to create a list variable to which you append every completed sentence, so that those sentences can later easily be called. To do this you'd put an inline_script right after the text_input form, in which you insert something like this in the run-phase:

        exp.sentence_list.append(exp.get('response'))
    

    At the beginning of your experiment you will have to put another inline_script where you create the variable, by inserting the line

        exp.sentence_list = []
    

    After the sentence completion trials you'll still have to create the second part of course. This will involve keeping count of the trial number, for instance by creating the variable exp.trial_count = 0 in a script (run-phase) placed prior to the second experiment part, and updating its value by means of exp.trial_count += 1 in a script placed at the end of the trial sequence.
    You can now call each completed sentence by means of [sentence_list[trial_sequence]], for example in another form where you then collect the participants ratings.

    Cheers

    Josh

  • Hi Josh,
    Thank you very much for your kind answer.
    Unfortunately, it didn't work for me.
    Before running a loop, I first tried to create a single trial.
    Firstly, I created an inline script:

    exp.sentence_list = []
    exp.trial_count = 0
    

    Afterward, I created new text form and then another inline script:

    exp.sentence_list.append(exp.get('response'))
    exp.trial_count += 1 
    

    Finally, I used multiple choice form and in the "Your question" tab, I wrote [sentence_list[trial_sequence]]

    Sadly it stopped after responding the free text form with the error:

    The variable 'trial_sequence' does not exist.

    Did I miss anything?

Sign In or Register to comment.