saving order of randomly presented text to use on another group of texts


Author
Message
maschap
maschap
New Member (6 reputation)New Member (6 reputation)New Member (6 reputation)New Member (6 reputation)New Member (6 reputation)New Member (6 reputation)New Member (6 reputation)New Member (6 reputation)New Member (6 reputation)
Group: Forum Members
Posts: 2, Visits: 18
Dave - 6/4/2025
maschap - 6/4/2025
Hi! I am conducting an experiment in two blocks, with slightly different texts for one and two. But I would like to save the order the texts were drawn in, to repeat it in the second block. Here's the script for block 1, block 2 is built up in the same way (same amount of trials, just different questions listed after the text on the survey page.)
Thank you so much for the help!

<block block1>
/ trials = [1 - 8 = noreplace(questions1); 9 = intro2]
</block>

    <surveyPage questions1>
    / stimulusFrames = [0 = texts1]
    / questions = [1=plausibleA;2=plausibleB;3=typicalA;4=typicalB;5=narrativeA;6=narrativeB;7=sodA;8=sodB]
    / showquestionnumbers = false
    / showpagenumbers = false
    / finishlabel = "Weiter"
    / nextButtonPosition = (50%,160%)
    </surveypage>

    <text texts1>
    / items = texts1
    / position = (50%, 15%)
    / size = (90%, 30%)
    </text>

    <item texts1>
    /1 = "Sie sind eine medizinische Fachkraft in einem Krankenhaus. ...
    ~n~n"
    
    /2 = "Sie bemerken einen führerlosen Güterwaggon, der sich auf den Gleisen schnell auf eine Gruppe von 5 Gleisarbeitern zubewegt...
    ~n~n"
    
    /3 = "Sie fahren eine Stadtstraße entlang, als auf einmal eine junge Mutter mit einem Kind im Arm stolpert und auf die Straße fällt...
    ~n~n"
    
    /4 = "Sie arbeiten bei der Feuerwehr und versuchen, Personen aus einem Hochhaus zu retten, in dem im 20. Geschoss ein Feuer ausgebrochen ist...
    ~n~n"
    
    /5 = "capsize...
    ~n
    ~n~n"
    
    /6 = "Sie sind Großbritanniens Premierminister:in während des 2. Weltkriegs...
    ~n~n"
    
    /7 = "Sie sind Ärzt:in in einem Krankenhaus einer Kreisstadt in Süddeutschland...
    ~n~n"
    
    /8 = "Sie sind Crewmitglied auf einem U-Boot und befinden sich unter einem großen Eisberg...
    ~n~n"
    </item>

<surveyPage intro2>
/ stimulusFrames = [1 = intro2]
</surveyPage>

<text intro2>
"Nun beginnen Sie den zweiten Teil der Studie. Hier werden Sie alle Szenarien noch einmal lesen und Ihre Entscheidung abgeben, die Schwierigkeit der Entscheidung und Ihre Aufgewühltheit bewerten."
</text>

The bottom line is you set up a <list> /onExptBegin with items 1 to 8 randomly ordered, and then you just use that list for item selection in both blocks.

<expt a>
/ onExptBegin = [
    list.fixedOrder.appenditem(list.allItems.nextIndex);
    list.fixedOrder.appenditem(list.allItems.nextIndex);
    list.fixedOrder.appenditem(list.allItems.nextIndex);
    list.fixedOrder.appenditem(list.allItems.nextIndex);
]
/ blocks = [1=blockOne; 2=blockTwo]
</expt>

// four items in this example
<list allItems>
/ poolsize = 4
/ selectionrate = always
/ selectionmode = random
</list>

<list fixedOrder>
/ selectionmode = sequence
</list>

<block blockOne>
/ trials = [1-4 = pageOne]
</block>

<block blockTwo>
/ trials = [1-4 = pageTwo]
</block>

<surveyPage pageOne>
/ stimulusframes = [1=textOne]
/ caption = "Block One"
/ showpagenumbers = false
/ showquestionnumbers = false
</surveypage>

<surveyPage pageTwo>
/ stimulusframes = [1=textTwo]
/ caption = "Block Two"
/ showpagenumbers = false
/ showquestionnumbers = false
</surveypage>

<text textOne>
/ items = itemOne
/ select = list.fixedOrder.nextValue
</text>

<text textTwo>
/ items = itemTwo
/ select = list.fixedOrder.nextValue
</text>

<item itemOne>
/ 1 = "A1"
/ 2 = "B1"
/ 3 = "C1"
/ 4 = "D1"
</item>

<item itemTwo>
/ 1 = "A2"
/ 2 = "B2"
/ 3 = "C2"
/ 4 = "D2"
</item>


This question has been answered in the forum numerous times, so you can find many examples via search.
Thank you Dave!

Dave
Dave
Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)
Group: Administrators
Posts: 13K, Visits: 108K
maschap - 6/4/2025
Hi! I am conducting an experiment in two blocks, with slightly different texts for one and two. But I would like to save the order the texts were drawn in, to repeat it in the second block. Here's the script for block 1, block 2 is built up in the same way (same amount of trials, just different questions listed after the text on the survey page.)
Thank you so much for the help!

<block block1>
/ trials = [1 - 8 = noreplace(questions1); 9 = intro2]
</block>

    <surveyPage questions1>
    / stimulusFrames = [0 = texts1]
    / questions = [1=plausibleA;2=plausibleB;3=typicalA;4=typicalB;5=narrativeA;6=narrativeB;7=sodA;8=sodB]
    / showquestionnumbers = false
    / showpagenumbers = false
    / finishlabel = "Weiter"
    / nextButtonPosition = (50%,160%)
    </surveypage>

    <text texts1>
    / items = texts1
    / position = (50%, 15%)
    / size = (90%, 30%)
    </text>

    <item texts1>
    /1 = "Sie sind eine medizinische Fachkraft in einem Krankenhaus. ...
    ~n~n"
    
    /2 = "Sie bemerken einen führerlosen Güterwaggon, der sich auf den Gleisen schnell auf eine Gruppe von 5 Gleisarbeitern zubewegt...
    ~n~n"
    
    /3 = "Sie fahren eine Stadtstraße entlang, als auf einmal eine junge Mutter mit einem Kind im Arm stolpert und auf die Straße fällt...
    ~n~n"
    
    /4 = "Sie arbeiten bei der Feuerwehr und versuchen, Personen aus einem Hochhaus zu retten, in dem im 20. Geschoss ein Feuer ausgebrochen ist...
    ~n~n"
    
    /5 = "capsize...
    ~n
    ~n~n"
    
    /6 = "Sie sind Großbritanniens Premierminister:in während des 2. Weltkriegs...
    ~n~n"
    
    /7 = "Sie sind Ärzt:in in einem Krankenhaus einer Kreisstadt in Süddeutschland...
    ~n~n"
    
    /8 = "Sie sind Crewmitglied auf einem U-Boot und befinden sich unter einem großen Eisberg...
    ~n~n"
    </item>

<surveyPage intro2>
/ stimulusFrames = [1 = intro2]
</surveyPage>

<text intro2>
"Nun beginnen Sie den zweiten Teil der Studie. Hier werden Sie alle Szenarien noch einmal lesen und Ihre Entscheidung abgeben, die Schwierigkeit der Entscheidung und Ihre Aufgewühltheit bewerten."
</text>

The bottom line is you set up a <list> /onExptBegin with items 1 to 8 randomly ordered, and then you just use that list for item selection in both blocks.

<expt a>
/ onExptBegin = [
    list.fixedOrder.appenditem(list.allItems.nextIndex);
    list.fixedOrder.appenditem(list.allItems.nextIndex);
    list.fixedOrder.appenditem(list.allItems.nextIndex);
    list.fixedOrder.appenditem(list.allItems.nextIndex);
]
/ blocks = [1=blockOne; 2=blockTwo]
</expt>

// four items in this example
<list allItems>
/ poolsize = 4
/ selectionrate = always
/ selectionmode = random
</list>

<list fixedOrder>
/ selectionmode = sequence
</list>

<block blockOne>
/ trials = [1-4 = pageOne]
</block>

<block blockTwo>
/ trials = [1-4 = pageTwo]
</block>

<surveyPage pageOne>
/ stimulusframes = [1=textOne]
/ caption = "Block One"
/ showpagenumbers = false
/ showquestionnumbers = false
</surveypage>

<surveyPage pageTwo>
/ stimulusframes = [1=textTwo]
/ caption = "Block Two"
/ showpagenumbers = false
/ showquestionnumbers = false
</surveypage>

<text textOne>
/ items = itemOne
/ select = list.fixedOrder.nextValue
</text>

<text textTwo>
/ items = itemTwo
/ select = list.fixedOrder.nextValue
</text>

<item itemOne>
/ 1 = "A1"
/ 2 = "B1"
/ 3 = "C1"
/ 4 = "D1"
</item>

<item itemTwo>
/ 1 = "A2"
/ 2 = "B2"
/ 3 = "C2"
/ 4 = "D2"
</item>


This question has been answered in the forum numerous times, so you can find many more examples via search.
Edited 2 days ago @ 4:07 AM by Dave
maschap
maschap
New Member (6 reputation)New Member (6 reputation)New Member (6 reputation)New Member (6 reputation)New Member (6 reputation)New Member (6 reputation)New Member (6 reputation)New Member (6 reputation)New Member (6 reputation)
Group: Forum Members
Posts: 2, Visits: 18
Hi! I am conducting an experiment in two blocks, with slightly different texts for one and two. But I would like to save the order the texts were drawn in, to repeat it in the second block. Here's the script for block 1, block 2 is built up in the same way (same amount of trials, just different questions listed after the text on the survey page.)
Thank you so much for the help!

<block block1>
/ trials = [1 - 8 = noreplace(questions1); 9 = intro2]
</block>

    <surveyPage questions1>
    / stimulusFrames = [0 = texts1]
    / questions = [1=plausibleA;2=plausibleB;3=typicalA;4=typicalB;5=narrativeA;6=narrativeB;7=sodA;8=sodB]
    / showquestionnumbers = false
    / showpagenumbers = false
    / finishlabel = "Weiter"
    / nextButtonPosition = (50%,160%)
    </surveypage>

    <text texts1>
    / items = texts1
    / position = (50%, 15%)
    / size = (90%, 30%)
    </text>

    <item texts1>
    /1 = "Sie sind eine medizinische Fachkraft in einem Krankenhaus. ...
    ~n~n"
    
    /2 = "Sie bemerken einen führerlosen Güterwaggon, der sich auf den Gleisen schnell auf eine Gruppe von 5 Gleisarbeitern zubewegt...
    ~n~n"
    
    /3 = "Sie fahren eine Stadtstraße entlang, als auf einmal eine junge Mutter mit einem Kind im Arm stolpert und auf die Straße fällt...
    ~n~n"
    
    /4 = "Sie arbeiten bei der Feuerwehr und versuchen, Personen aus einem Hochhaus zu retten, in dem im 20. Geschoss ein Feuer ausgebrochen ist...
    ~n~n"
    
    /5 = "capsize...
    ~n
    ~n~n"
    
    /6 = "Sie sind Großbritanniens Premierminister:in während des 2. Weltkriegs...
    ~n~n"
    
    /7 = "Sie sind Ärzt:in in einem Krankenhaus einer Kreisstadt in Süddeutschland...
    ~n~n"
    
    /8 = "Sie sind Crewmitglied auf einem U-Boot und befinden sich unter einem großen Eisberg...
    ~n~n"
    </item>

<surveyPage intro2>
/ stimulusFrames = [1 = intro2]
</surveyPage>

<text intro2>
"Nun beginnen Sie den zweiten Teil der Studie. Hier werden Sie alle Szenarien noch einmal lesen und Ihre Entscheidung abgeben, die Schwierigkeit der Entscheidung und Ihre Aufgewühltheit bewerten."
</text>

GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Reading This Topic

Explore
Messages
Mentions
Search