Hi there,
I am having trouble figuring out how to program the following task. What I want to have happen is for subjects to view (one at a time) 50 of a pool of 104 terms and answer 1 or 2 questions about it. I want each word to appear on the page with the radiobutton question underneath:
<radiobuttons>
/ caption = "Is this a good, bad or neutral (neither good nor bad) characteristic?"
/ options = ("good", "bad", "neutral", "I don't understand what this means")
/ optionvalues = ("1", "-1", "0", "-777")
</radiobuttons>
Then, depending on the response clicked, I want a second question to appear either underneath (or on a new page if same page isn't possible) that is one of the following:
if they responded "good":
<radiobuttons howgood>
/ caption = "How good is it?"
/ options = ("A little", " ", " ", " ", "A lot")
/ optionvalues = ("1", "2", "3", "4", "5")
/ orientation = horizontal
if they responded "bad":
<radiobuttons howbad>
/ caption = "How bad is it?"
if they responded "neutral" or "I don't understand...":
<caption skipto>
/ caption = "Click 'continue' to move on to the next item."
</caption>
I want this series of items, paired with question 1 (good/bad?) and the conditional question 2 (how good/bad?) to be repeated 50 times (noreplace) from among the 104 terms.
I cannot figure out how to set this up, though I am sure it must be possible. I am new to Inquisit; I checked the documentation and forums, but couldn't find examples parallel to what I am trying to accomplish.
Thanks for your help!
Lizeroo:I cannot figure out how to set this up, though I am sure it must be possible.
Well, it is possible, at least sort of. Attached you find a basic template script to check out (samples a subset of 5 out of 10 items instead of 50 out of 104). However, there is an issue with the script as it is. Basically, there's a nasty and hard-to-fix bug which prevents <surveypage> elements from being reused properly and efficiently (e.g. the '/ required' attribute setting will only work on the page's first run, previous answers aren't cleared...). There are a number of ways to work around this, although none of them are optimal solutions:
(1) Setting up separate <surveypage> elements for each item, resulting in approx. 210 pages in your case. That's serious code-bloat and managing changes will be a pain.
(2) Build a "custom" survey layout using standard <trial> elements. Personally, I'd go with this option although it would require a bit of advanced coding. Maybe check out the "custom likert scales" script (http://www.millisecond.com/download/samples/v2/CustomLikert/customlikert.zip) for some inspiration.
~Dave
"To understand recursion, you must first understand recursion." - Unknown Zen Master
Hi Dave,Thanks for getting back to me so quickly. Your second option sounds promising; I may try that for the final study. As I am still a novice and this is just a pilot project so far, I decided to give up on my radiobutton dreams and try presenting likert response scales instead. It seems to be working well and storing the data in a format that will be easy to rearrange later for analysis. Here's the syntax that works:
<item guestcharitems>
/1 = "Smiles a lot"
/2 = "Rarely smiles"
/3 = "Likes the same music as you"
...
/104 = "Doesn’t like to cook"
</item>
<text guestchartext>
/ items = guestcharitems
/ position = (50%, 40%)
/ fontstyle = ("Arial", 5%, true)
</text>
<text goodbadtext>
/ items = ("Is this characteristic good, bad or neutral (neither good nor bad)?")
/ fontstyle = ("Arial", 3%, false)
<text howgoodtext>
/ items = ("How good is it?")
/ position = (50%, 30%)
<text howbadtext>
/ items = ("How bad is it?")
<text skiptotext>
/ items = ("Click 'continue' to move on to the next item.")
<text guestprompt>
/ items = ("He or she...")
<likert guestgoodbad>
/ stimulusframes = [1=guestchartext, goodbadtext, guestprompt]
/ anchors = [1="good", 2="bad", 3="neutral", 4="not sure what this means"]
/ buttonvalues = [1="1", 2="-1", 3="0", 4="-777"]
/ fontstyle = ("Arial", 2%, true)
/ numpoints = 4
/ branch = [if (likert.guestgoodbad.response == 1) likert.howgood]
/ branch = [if (likert.guestgoodbad.response == -1) likert.howbad]
/ branch = [if (likert.guestgoodbad.response == 0) likert.skipto]
/ branch = [if (likert.guestgoodbad.response == -777) likert.skipto]
</likert>
<likert howgood>
/ stimulusframes = [1=howgoodtext]
/ anchors = [1="a little good", 7="very good"]
/ numpoints = 7
<likert howbad>
/ stimulusframes = [1=howbadtext]
/ anchors = [1="a little bad", 7="very bad"]
<likert skipto>
/ stimulusframes = [1=skiptotext]
/ anchors = [1="continue"]
/ buttonvalues = [1="-777"]
/ numpoints = 1
<block houseguestblock>
/ trials = [1-50=noreplace(guestgoodbad)]
</block>
[Sorry about the double spacing...]