hungry donkey getting more hungry: feedback problem


Author
Message
HTibboel
HTibboel
Expert (1.3K reputation)Expert (1.3K reputation)Expert (1.3K reputation)Expert (1.3K reputation)Expert (1.3K reputation)Expert (1.3K reputation)Expert (1.3K reputation)Expert (1.3K reputation)Expert (1.3K reputation)
Group: Forum Members
Posts: 7, Visits: 1

Hi all,


We are currently programming an experiment using inquisit 2.0 in which participants are required to choose one out of 4 doors. Depending on the chosen door, a number of points is won or lost. This number differs over doors AND trials (cfr. Iowa gambling task). On each trial, feedback should be given concerning the points won and lost on the current trial, AND the total amount of points. Does anyone have an idea on how to keep track of the points scored on each trial, on how to calculate the total score, and on how to present these scores to the participant?


Thanking you in advance,


Kasia, Helen & Bram


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: 103K
If I'm not totally off, there is absolutely no way to do this with Inquisit 2.0. You'll most definitely have to consider upgrading to version 3.0 to get advanced features such as keeping track of scores, being able to use mathematical expressions in scripts etc.

Best,
~Dave

seandr
seandr
Supreme Being (143K reputation)Supreme Being (143K reputation)Supreme Being (143K reputation)Supreme Being (143K reputation)Supreme Being (143K reputation)Supreme Being (143K reputation)Supreme Being (143K reputation)Supreme Being (143K reputation)Supreme Being (143K reputation)
Group: Administrators
Posts: 1.3K, Visits: 5.6K

I've heard of some customers using trialcount on dummy trials to track points. Basically, you branch to a certain type of dummy trial and then repeat that trial for as many points as you want to reward. This approach is cumbersome, and it's quite limited in what you can do.


Inquisit 3, on the other hand, has a whole bunch of new features designed to support exactly this kind of task. Check out our Iowa Gambling Task sample, for example:


http://www.millisecond.com/download/samples/v3/IowaGamblingTask/default.aspx


If you can swing it, you should upgrade to Inquisit 3.


-Sean


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: 103K
Dear Kasia, Helen & Bram,

I've heard of some customers using trialcount on dummy trials to track points. Basically, you branch to a certain type of dummy trial and then repeat that trial for as many points as you want to reward. This approach is cumbersome, and it's quite limited in what you can do.


... the most relevant limitation being that you can only *add* points with no way to *subtract* points as would be required by your paradigm. Sorry for me being such a smart-***, Sean! I love the trialcount approach for its obvious creativity, though.

Best,
~Dave

HTibboel
HTibboel
Expert (1.3K reputation)Expert (1.3K reputation)Expert (1.3K reputation)Expert (1.3K reputation)Expert (1.3K reputation)Expert (1.3K reputation)Expert (1.3K reputation)Expert (1.3K reputation)Expert (1.3K reputation)
Group: Forum Members
Posts: 7, Visits: 1

Thank you for your tips! In the meantime I managed to upgrade it to Inquisit 3. However, branching does not seem to work. I am comparing my script with the IGT, however, I can't find my mistake. Can anyone help me on that please (cfr. infra)?


Regards,


Kasia


**************



<trial trial_ID1>


/ ontrialbegin = [picture.door_1.item.1 = "door_1.jpg"; picture.door_2.item.1 = "door_2.jpg"; picture.door_3.item.1 = "door_3.jpg"; picture.door_4.item.1 = "door_4.jpg";]


/ stimulustimes = [1=door_1,door_2, door_3, door_4, donkey; 6000 = CUE]


/ responsetime = 6000


/ response = timeout(1000)


/ validresponse = ("q","s", "k", "l")


/ branch = [if (true) trial.HD_ID1_feedback]


</trial>


<trial HD_ID1_feedback>


/ ontrialbegin = [ if (trial.trial_ID1.response == "q") {picture.door_1.item.1 = "8r_4g.jpg"; text.gain.hposition=picture.door_1.hposition; text.loss.hposition=picture.door_1.hposition; values.gain=4; values.loss= 8; values.currenttotal = values.currenttotal+values.gain-values.loss}]


/ ontrialbegin = [ if (trial.trial_ID1.response == "s") {picture.door_2.item.1 = "50r_4g.jpg"; text.gain.hposition=picture.door_2.hposition; text.loss.hposition=picture.door_2.hposition; values.gain=4; values.loss=50; values.currenttotal = values.currenttotal+values.gain-values.loss}]


/ ontrialbegin = [ if (trial.trial_ID1.response == "k") {picture.door_3.item.1 = "1r_2g.jpg"; text.gain.hposition=picture.door_3.hposition; text.loss.hposition=picture.door_3.hposition; values.gain=2; values.loss=1; values.currenttotal = values.currenttotal+values.gain-values.loss}]


/ ontrialbegin = [ if (trial.trial_ID1.response == "l") {picture.door_4.item.1 = "10r_2g.jpg"; text.gain.hposition=picture.door_4.hposition; text.loss.hposition=picture.door_4.hposition; values.gain=2; values.loss=10; values.currenttotal = values.currenttotal+values.gain-values.loss}]


/ stimulustimes = [1=door_1, door_2, door_3, door_4, gain, loss, huidig_totaal]


</trial>


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: 103K
Can you zip your script along with any external files needed (images, etc.) and upload it somewhere? I'd be happy to take a look - but the debugging will be much easier with the full script at hand. You can use free file hosters like rapidshare or megaupload to upload the file and then post the download link here.

Best,
~Dave

seandr
seandr
Supreme Being (143K reputation)Supreme Being (143K reputation)Supreme Being (143K reputation)Supreme Being (143K reputation)Supreme Being (143K reputation)Supreme Being (143K reputation)Supreme Being (143K reputation)Supreme Being (143K reputation)Supreme Being (143K reputation)
Group: Administrators
Posts: 1.3K, Visits: 5.6K

I don't see any problem with your branch, but you might try removing the "if (true)" part, as in:


/ branch = [trial.HD_ID1_feedback]


This is logically equivalent to what you currently have.


-Sean


HTibboel
HTibboel
Expert (1.3K reputation)Expert (1.3K reputation)Expert (1.3K reputation)Expert (1.3K reputation)Expert (1.3K reputation)Expert (1.3K reputation)Expert (1.3K reputation)Expert (1.3K reputation)Expert (1.3K reputation)
Group: Forum Members
Posts: 7, Visits: 1

Hi Dave,


That's really kind of you!!We are really panicking now..


On the next site you can find our stimuli and scripts: http://www.megaupload.com/?d=ULZ0BP4D


The design of the task is as follows:


If you run the block 'sukeltjes' (this is a block in which we tried to program one branching trial, don't mind the other trials, because the design will be the same for them), you should see four doors; the participant has to choose one door by pressing q,s,k, OR l on a standard azerty keyboard. Depending on the chosen door, a certain reward is given (apples):


for door 1 = 4 apples won and 8 apples lost


for door 2 = 4 apples won and 50 lost


for door 3 = 2 apples won and 1 lost


for door 4 = 2 apples won and 10 lost


Feedback should be: the chosen door should be replaced by an open door showing the amount of apples lost and won (e.g. see picture 8r_4g.jpg), the total amount of apples gathered over trials (instead of the donkey), in the lower right corner: a bar showing visually the gains and losses (e.g. Bar13_87.jpg) on that particular trial with underneath the gains and losses on that particular trial in numbers (e.g. +4 and -8). For instance, if the participant gained a total of 6-19 apples over all trials, the bar 13_87 should be presented next to the fourth door. All feedback should be given at the same time during 2500ms.


Do you see the problem in the script?


I hope you can help us out, since we are really getting short in time.


Regards,


Kasia & Bram



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: 103K
I've had a look at your files and - as it seems - you've hit on a few Inquisit bugs. So, from what I can tell, it's not really your fault that things aren't working as they should. Here's a workaround for you, though. The general problem is that the /ontrialend and /ontrialbegin branches appear to have a hard time to work with keypress responses when they're given as "literal" values:

/ ontrialbegin = [if(trial.trial_ID1.response == "s") ...]

If you use the key's scancode (see here: http://www.millisecond.com/support/docs/v3/html/language/scancodes.htm) instead, the script will start working. The scancode for the S-key is 31:

/ ontrialbegin = [if(trial.trial_ID1.response == "31") ...]

Also, if you switch the script to accept mouse instead of keyboard responses, it starts working as expected. I've attached a small test script based on your original file to demonstrate what I described above. I additionally recommend emailing Sean about the issue.

Now that you can have the core functions of your script running, I hope you'll be able to figure out the further details without too much hassle.

Best,
~Dave

Attachments
Donkey_Debug.exp (531 views, 3.00 KB)
seandr
seandr
Supreme Being (143K reputation)Supreme Being (143K reputation)Supreme Being (143K reputation)Supreme Being (143K reputation)Supreme Being (143K reputation)Supreme Being (143K reputation)Supreme Being (143K reputation)Supreme Being (143K reputation)Supreme Being (143K reputation)
Group: Administrators
Posts: 1.3K, Visits: 5.6K

I believe the issue is that the response property returns the scancode of the key that was pressed, not the character value. The following conditional would thus never evaluate to true:


/ ontrialbegin = [if(trial.trial_ID1.response == "s") ...]


However, the following would be true if the subject pressed the "s" key:


/ ontrialbegin = [if(trial.trial_ID1.response == 31...]


because the scancode for "s" is 31. You can figure out scan codes for other keys using the Scancode tool on the Tools menu.


Is this a bug? Well, not exactly although it's not ideal either. Intuitively, both of these conditionsal statements should evaluate to true, so it's a matter of having the response property return different values depending on whether it's being compared with a string or a number. As of yet, no other property works that way, and it would require some mucking around with the expression evaluator to do this properly. I'll certainly put it on my list of possible features for a future release.


-Sean


GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Reading This Topic

Explore
Messages
Mentions
Search