Inquisit 4 to Inquisit 3


Author
Message
nonamenick
nonamenick
Distinguished Member (3K reputation)Distinguished Member (3K reputation)Distinguished Member (3K reputation)Distinguished Member (3K reputation)Distinguished Member (3K reputation)Distinguished Member (3K reputation)Distinguished Member (3K reputation)Distinguished Member (3K reputation)Distinguished Member (3K reputation)
Group: Awaiting Activation
Posts: 20, Visits: 100
Thank you, the experiment is running however, it is appending only the first item and not a random trial. And on the payout page, it is saying that trial number picked at random is trial 1 and it does not show the payout. I'm not sure if its a problem with the script in the trials above or an error with the trials for the payout page that i've posted here.

<trial chosenslide>
/stimulusframes = [1=endslide]
/inputdevice = keyboard
/validresponse = ("q")
</trial>

<picture endslide>
/ items = endslide
/ select = current(payout)
/ size = (50%,50%)
/ position = (50%,55%)
</picture>

<trial payouttrial>
/ stimulusframes = [1=payoutmsg, payout, trialmsg]
/inputdevice = keyboard
/ validresponse = ("q")
</trial>

<text payoutmsg>
/ items = ("Your payout is")
/ position = (50%, 40%)
</text>

<text payout>
/ items = storedwinnings
</text>

<text trialmsg>
/ items = ("which is the amount you won in trial #<%text.payout.currentitemnumber%>.")
/ position = (50%, 60%)
</text>

<item storedwinnings>
</item>

<item endslide>
</item>



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: 104K
The code is too incomplete to say anything specific. Note that the selection in your <picture> element is set to depend on the selection in some other element:

<picture endslide>
/ items = endslide
/ select = current(payout)
/ size = (50%,50%)
/ position = (50%,55%)
</picture>

For this to make sense, the selection in the "payout" element has to happen *before* you ever try to display the <picture>. That would be a good place to start looking for your error.

nonamenick
nonamenick
Distinguished Member (3K reputation)Distinguished Member (3K reputation)Distinguished Member (3K reputation)Distinguished Member (3K reputation)Distinguished Member (3K reputation)Distinguished Member (3K reputation)Distinguished Member (3K reputation)Distinguished Member (3K reputation)Distinguished Member (3K reputation)
Group: Awaiting Activation
Posts: 20, Visits: 100
Ok, I changed the select so that it is it is the text payout that is selecting the endslide instead of the opposite way. The trial number is coming up using this <%text.payout.currentitemnumber%>. 

The only thing still not showing up is storedwinnings. After each trial is changes the win value to either 0, 5, or a win amount depending on the outcome of the lottery. 

I don't have anything for storedwinnings in the trial script. 

<trial fixedtrial>
/ ontrialbegin = [values.probamount=counter.slidevalues.selectedvalue; values.prob=counter.slideprob.selectedvalue; values.win=0; ]
/ ontrialbegin = [values.randomnumber = rand(0,100); ]
/ ontrialbegin = [picture.risk_slides]
/ ontrialend = [if (trial.fixedtrial.response=="3") {values.win=values.fixedamount; }; ]
/ ontrialend = [if (trial.fixedtrial.response=="1" && values.prob >= values.randomnumber) {values.win=values.probamount; }; ]
/ ontrialend = [if (trial.fixedtrial.response=="1" && values.prob < values.randomnumber) {values.win=0; }; ]
/ ontrialend = [item.endslide.item = picture.risk_slides.currentitem]
/ stimulusframes = [1=3, 1, risk_slides]
/ inputdevice = mouse
/ response = timeout(10000)
/ validresponse = (3, 1)
/ posttrialpause = 500
</trial>

and was wondering if it had to be in there or if the value gets stored with the item.endslide

<text payout>
/ items = storedwinnings
/ select = current(endslide)
</text>

<text trialmsg>
/ items = ("which is the amount you won in trial #<%text.payout.currentitemnumber%>.")
/ position = (50%, 60%)
</text>

<item storedwinnings>
</item>

Does something involving the win.value need to go into the storedwinnings item? 


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: 104K
> Does something involving the win.value need to go into the storedwinnings item?

I cannot answer this question but you should be able to. You wrote the original Inquisit 4 code that used those <item> elements and that should tell you where they were used and what for.

All I can say is that you have a <text> element

<text payout>
/ items = storedwinnings
/ select = current(endslide)
</text>

<item storedwinnings>
</item>

that references <item storedwinnings> and that the selection in the <text> element depends on the selection in "endslide". If you don't ever add any items to <item storedwinnings>, it obviously cannot display anything.

GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Reading This Topic

Explore
Messages
Mentions
Search