Millisecond Forums

Use different list for each condition in one script

https://forums.millisecond.com/Topic28003.aspx

By labdandeneau@gmail.com - 11/16/2019

Hi, 
I'm modifying the Cyberball script and have created 2 sets of lists of playerschedules - one for each condition I want to run. I.e. List 1 runs the standard Inclusion schedule and List 2 runs an OverInclusion schedule. I would like to use Subject assignment where Group 1 = List 1, Group 2 = List 2.  

I was thinking of using an <include> element where I include "List1.iqx" for those with odd numbered groupid and "List2.iqx" for participants with even numbered groupid.... MY QUESTION: how do I use even/odd groupid in the precondition statement?

Obviously this doesn't work.. but shows what I'm trying to do: 
<include>
/ file = "List1.iqx"
/ precondition = [groupid = 1]
</include>

<include>
/ file = "List2.iqx"
/ precondition = [groupid = 2]
</include>

Thanks in advance

By Dave - 11/17/2019

Hi, 
I'm modifying the Cyberball script and have created 2 sets of lists of playerschedules - one for each condition I want to run. I.e. List 1 runs the standard Inclusion schedule and List 2 runs an OverInclusion schedule. I would like to use Subject assignment where Group 1 = List 1, Group 2 = List 2.  

I was thinking of using an <include> element where I include "List1.iqx" for those with odd numbered groupid and "List2.iqx" for participants with even numbered groupid.... MY QUESTION: how do I use even/odd groupid in the precondition statement?

Obviously this doesn't work.. but shows what I'm trying to do: 
<include>
/ file = "List1.iqx"
/ precondition = [groupid = 1]
</include>

<include>
/ file = "List2.iqx"
/ precondition = [groupid = 2]
</include>

Thanks in advance


Like so:

<include>
/ file = "List1.iqx"
/ precondition = [mod(script.groupid, 2) == 1]
</include>

<include>
/ file = "List2.iqx"
/ precondition = [mod(script.groupid, 2) == 0]
</include>
By labdandeneau@gmail.com - 11/17/2019

Dave - 11/18/2019

Hi, 
I'm modifying the Cyberball script and have created 2 sets of lists of playerschedules - one for each condition I want to run. I.e. List 1 runs the standard Inclusion schedule and List 2 runs an OverInclusion schedule. I would like to use Subject assignment where Group 1 = List 1, Group 2 = List 2.  

I was thinking of using an <include> element where I include "List1.iqx" for those with odd numbered groupid and "List2.iqx" for participants with even numbered groupid.... MY QUESTION: how do I use even/odd groupid in the precondition statement?

Obviously this doesn't work.. but shows what I'm trying to do: 
<include>
/ file = "List1.iqx"
/ precondition = [groupid = 1]
</include>

<include>
/ file = "List2.iqx"
/ precondition = [groupid = 2]
</include>

Thanks in advance


Like so:

<include>
/ file = "List1.iqx"
/ precondition = [mod(script.groupid, 2) == 1]
</include>

<include>
/ file = "List2.iqx"
/ precondition = [mod(script.groupid, 2) == 0]
</include>

Awesome... thanks a lot.