Branching according to subject's ID


Author
Message
Andzue
Andzue
Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)
Group: Forum Members
Posts: 6, Visits: 39
Hi there

I'm implementing a go/no-go task with Inquisit 3.0 and have two conditions (experimental group and control group). I would like to set up a branch command so that Inquisit either chooses the experimental condition or the control condition, according to the subject's ID. Even numbers should be assigned to the control condition and odd numbers to the experimental condition (in order to have counterbalanced groups).

I guess the branch command should be used here, but I don't know how to tell Inquisit to use the subjects' ID as a reference.

Do you have any ideas?

Thanks a lot in advance.

Best,
Andrea
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: 12K, Visits: 98K
In general you should use <expt> elements and their /subjects attributes to implement between subjects conditions. I.e.

<expt experimentalcondition>
/ subjects = (1 of 2)
/ blocks = [ blocks to run in the experimental condition ]
</expt>

<expt controlcondition>
/ subjects = (2 of 2)
/ blocks = [ blocks to run in the control condition ]
</expt>

To also answer your original question, if you want to branch based on odd vs. even subject ID, you use the script.subjectid property and the mod() function:

/ branch = [if (mod(script.subjectid, 2)==0) block.controlcondition else block.experimentalcondition]

Andzue
Andzue
Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)
Group: Forum Members
Posts: 6, Visits: 39
Thank you very much for your helpful reply!

Best,
Andrea
Andzue
Andzue
Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)
Group: Forum Members
Posts: 6, Visits: 39

Hi Dave

I have another question regarding my go/no-go task. I would like to present 140pictures in a given order, which I have defined with the aid of the followingcode:

<pictureexperimental_pics1>

/ items =experimental_pics1

/ select =sequence

/ size =(200mm,200mm)

/ position =(50%,50%)

/ erase =false

</picture>

 

<itemexperimental_pics1>

/1 = "0001.jpg"

/2 = "0002.jpg"

/3 = "0003.jpg"

/4 = "0004.jpg"

</item>

200ms after the picture ispresented, I would like a grey (nogo prime) or blue circle (go prime) to bepresented in one of the four corners of the picture. I have defined the primesas follows (example code of a blue circle appearing in the top right corner ofthe picture):

<itemgo_right_top>

/1 =  "O"

</item>

 

<textgo_right_top>

/items =  go_right_top

/position =(70,30)

/txcolor =(0, 0, 255)

/fontstyle =("Arial", 120pt)

 </text>

 

Since it is important that specific primes are coupled with specific pictures, I would like to present the primes in a given order as well, so that my trial would eventually look as follows:

<trialexperimental_condition>

/stimulustimes= [0=blankscreen; 500=experimental_pics1; 700=prime_experimental]

/validresponse = (57,0)

/correctresponse = (0)

/errormessage = true(falsch, 200)

/timeout = 2200

/responseinterrupt = immediate

/recorddate = true

/posttrialpause = 500

</trial>

 

Is is possible to do so, similar to the "sequence" command I used with the pictures? I've read about the <list> function in the forum here, but unfortunately couldn't find it in the language reference.
Thanks and best wishes,

Andrea 


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: 12K, Visits: 98K
> Since it is important that specific primes are coupled with specific pictures

What exactly does that mean? Please elaborate.

Andzue
Andzue
Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)
Group: Forum Members
Posts: 6, Visits: 39
It means that blue circles should always be paired with half of the pictures (food objects) and grey circles should always be paired with the other half of the pictures (non-food objects).
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: 12K, Visits: 98K
Well, normally you would set up two <trial> elements -- a "go" trial & a "no go" trial. The go trial would display your food pics and the blue "go" prime, the no go trial would display your non-food pics and the grey "no go" prime.

You run those trial elements in whatever order (i.e. sequence) you require.

Andzue
Andzue
Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)
Group: Forum Members
Posts: 6, Visits: 39

I've added my script to this post in order to clarify my inquiry.
I have done it the way you suggest, but my problem is that I would like my pictures to be in a set order, as well as the corresponding primes. So far, according to my script, the pictures are randomly presented as well as the primes (but food objects always paired with a grey prime (sorry, I've written it wrong in the previous post) and non-food objects always paired with a blue prime.

Is it possible to set the primes to a given order (such as the pictures)?

Thanks



Attachments
Go-No-Go Food Exp.exp (696 views, 20.00 KB)
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: 12K, Visits: 98K
You need to distinguish between *item* selection and *trial* selection. Those are different things.

If you want items in a given stimulus element (<text>, <picture>, etc.) to to be selected in a specific order, you set the /select attribute to sequence. You already know how to do that based on your previous posts.

To have your *trials* selected in a specific order, use the <block> element's /trials attribute. Suppose you have two <trial> elements -- a and b -- and you want to run four trials in the order a-b-b-a. You do:

<block someblock>
/ trials = [1,4=a; 2,3=b]
...
</block>

Andzue
Andzue
Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)Expert (1.2K reputation)
Group: Forum Members
Posts: 6, Visits: 39
I completely understand the difference between trial and item selection. Since I have 16 different trial elements (experimental and control condition) and a total of 140 trials per block I just wanted to know if there was an easier way to run the primes in a given order.




GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Reading This Topic

Explore
Messages
Mentions
Search