Data types?


Author
Message
Laura.Kwako
Laura.Kwako
Associate Member (169 reputation)Associate Member (169 reputation)Associate Member (169 reputation)Associate Member (169 reputation)Associate Member (169 reputation)Associate Member (169 reputation)Associate Member (169 reputation)Associate Member (169 reputation)Associate Member (169 reputation)
Group: Forum Members
Posts: 2, Visits: 2
Our IT department asked about which data type (text, integer) each variable is in the different tasks we're using.  Is there a quick place to find that, or should we look at the sample output files for that information?

Thanks!
Laura
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
Laura.Kwako - Wednesday, November 7, 2018
Our IT department asked about which data type (text, integer) each variable is in the different tasks we're using.  Is there a quick place to find that, or should we look at the sample output files for that information?

Thanks!
Laura

Variables in Inquisit have no fixed or a-priori declared data type, i.e. whether

<values>
/ example = 1
</values>

is treated as a string, integer, etc. depends on how it's used throughout the code, and the runtime will figure out the proper data type in each context on the fly. Since data output is highly configurable, there is no way to make a blanket statement about the data type of each logged variable either, this would indeed depend entirely on the script / its specific output.

Dana Leighton
Dana Leighton
Partner Member (803 reputation)Partner Member (803 reputation)Partner Member (803 reputation)Partner Member (803 reputation)Partner Member (803 reputation)Partner Member (803 reputation)Partner Member (803 reputation)Partner Member (803 reputation)Partner Member (803 reputation)
Group: Forum Members
Posts: 9, Visits: 36
Dave - Wednesday, November 7, 2018
is treated as a string, integer, etc. depends on how it's used throughout the code, and the runtime will figure out the proper data type in each context on the fly. Since data output is highly configurable, there is no way to make a blanket statement about the data type of each logged variable either, this would indeed depend entirely on the script / its specific output.

Interesting. So we could for example, do something like:
<values>
/ number = 1
</values>
<trial sometrial>
(someattributes)
</trial>
<trial someothertrial>
/ values.number = "A"
(someotherattributes)
</trial>

In this case, values.number in the context of sometrial would be an integer, but in the context of someothertrial, it would be a string?




--
Dana C. Leighton, PhD
Assistant Professor of Psychology, Texas A&M University—Texarkana

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
danaleighton - Wednesday, November 7, 2018
Dave - Wednesday, November 7, 2018
is treated as a string, integer, etc. depends on how it's used throughout the code, and the runtime will figure out the proper data type in each context on the fly. Since data output is highly configurable, there is no way to make a blanket statement about the data type of each logged variable either, this would indeed depend entirely on the script / its specific output.

Interesting. So we could for example, do something like:
<values>
/ number = 1
</values>
<trial sometrial>
(someattributes)
</trial>
<trial someothertrial>
/ values.number = "A"
(someotherattributes)
</trial>

In this case, values.number in the context of sometrial would be an integer, but in the context of someothertrial, it would be a string?


Apart from your example not being valid syntax, yes, it's perfectly possible for a given value to change it's data type on a trial-by-trial basis. E.g.

<values>
/ myvalue = 0
</values>

<list someintegers>
/ items = (10, 100, 1000, 10000)
</list>

<list somestrings>
/ items = ("a cat", "a dog", "a cow", "a bird")
</list>


<trial a>
/ ontrialbegin = [
values.myvalue = list.someintegers.nextvalue;
values.myvalue = values.myvalue / 2;
]
/ stimulusframes = [1=mytext]
/ validresponse = (57)
</trial>

<trial b>
/ ontrialbegin = [
values.myvalue = list.somestrings.nextvalue;
values.myvalue = concat(values.myvalue, " says...?")
]
/ stimulusframes = [1=mytext]
/ validresponse = (57)
</trial>

<text mytext>
/ items = ("<%values.myvalue%>")
</text>

<block myblock>
/ trials = [1-4 = sequence(a,b)]
</block>

<data>
/ columns = (date time subject group blocknum blockcode trialnum trialcode response latency values.myvalue)
/ separatefiles = true
</data>





Laura.Kwako
Laura.Kwako
Associate Member (169 reputation)Associate Member (169 reputation)Associate Member (169 reputation)Associate Member (169 reputation)Associate Member (169 reputation)Associate Member (169 reputation)Associate Member (169 reputation)Associate Member (169 reputation)Associate Member (169 reputation)
Group: Forum Members
Posts: 2, Visits: 2
Dave - Wednesday, November 7, 2018
Laura.Kwako - Wednesday, November 7, 2018
Our IT department asked about which data type (text, integer) each variable is in the different tasks we're using.  Is there a quick place to find that, or should we look at the sample output files for that information?

Thanks!
Laura

Variables in Inquisit have no fixed or a-priori declared data type, i.e. whether

<values>
/ example = 1
</values>

is treated as a string, integer, etc. depends on how it's used throughout the code, and the runtime will figure out the proper data type in each context on the fly. Since data output is highly configurable, there is no way to make a blanket statement about the data type of each logged variable either, this would indeed depend entirely on the script / its specific output.

Ah, got it.  Thanks for the reply.  I think we'll have to go through them individually and identify output for our programmer.  Thanks again!
GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Reading This Topic

Explore
Messages
Mentions
Search