Millisecond Forums

coding trials for data

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

By Katlyn.Frey@ColoradoCollege.edu - 6/29/2016

Hello!
How can I give half of my trials a certain marker (such as "same category") and the other half a different marker (such as "different category") and then have that information available in my data file--so I can sort the trials according to these two different markers? 
Does this make sense?
Thanks!
Katlyn
By Dave - 6/29/2016

Suppose you have two "same category" <trial> elements , and two "different category" <trial> elements.

Set up a <values> entry:

<values>
/ category = ""
...
</values>

and set that value to the appropriate label in your trials:

<trial same_a>
/ ontrialbegin = [values.category = "same category"]
...
</trial>

<trial same_b>
/ ontrialbegin = [values.category = "same category"]
...
</trial>


<trial different_a>
/ ontrialbegin = [values.category = "different category"]
...
</trial>

<trial different_b>
/ ontrialbegin = [values.category = "different category"]
...
</trial>

Specify the <data> element in the script to log the respective value:

<data>
/ columns = [date time subject group blocknum blockcode trialnum trialcode response latency correct ... values.category]
...
</data>

You can then sort by values.category as needed.