randomized, with constraints two images simultaneously presented and screen position randomized


randomized, with constraints two images simultaneously presented and...
Author
Message
shane
shane
Esteemed Member (1.6K reputation)Esteemed Member (1.6K reputation)Esteemed Member (1.6K reputation)Esteemed Member (1.6K reputation)Esteemed Member (1.6K reputation)Esteemed Member (1.6K reputation)Esteemed Member (1.6K reputation)Esteemed Member (1.6K reputation)Esteemed Member (1.6K reputation)
Group: Forum Members
Posts: 23, Visits: 92
I have what is probably a relatively straightforward couple of snags for more experienced Inquisit users.  I have 80 images, 40 of category A and 40 of category B.  On a given trial I need to have two images presented on the screen, one beside the other, along with some text (below or above the images, doesn't really matter).  However, I need the images to come from the aforementioned different lists/categories such that one is always from category A and the other from category B.  I'd like the images to be randomly selected without replacement across the entire experiment (that is, Ps never see the same image twice). Further, I'd prefer the spatial arrangement of the images on the page be counterbalanced or at least randomized, such that cat A images aren't always on the left and cat B always on the right, for example. 

The text will remain the same in one block, but change in another block.  And the block orders should be randomized (vignette 1 and vignette 2). 

Lastly, if possible, I'd prefer participants make their selection (which is one of the two photos), by clicking on the photo, and I'd prefer to be able to assign that as correct or incorrect within inquisit but not displayed to participants. The code below is a mess, I know, but it should provide a start.  I'm very appreciative of any insight provided.  Best, Shane

<defaults >
/ screencolor = (255, 255, 255)
</defaults>

<instruct>
/ windowsize = (1000px, 800px)
/ nextkey = (" ")
/ prevkey = ("5")
/ fontstyle = ("Arial", 2.05%, false, false, false, false, 5, 0)
/ wait = 2000
</instruct>
*********************************************************
************ALL INSTRUCTIONS********************
**********************************************************

<page introinstr1>Welcome and thanks for your participation!^^Today you will be viewing a brief description of an act committed by one of two people pictured on the screen^^
You will use the mouse to respond to select which of the two you think was more likely the one who committed the act described.
^^There will be four sets of 20 photos each.^^Feel free to rest after each block if you like. The entire study should last no more than 20-25 minutes.^^Press the SPACEBAR to continue for more instructions.
</page>

<page introinstr2>As just described, you will be shown photos of two men at the same time on the screen, with a description of a behavior performed by one of the two, but NOT by both.
^^Only one of the men depicted behaved in the manner described.^^Your task is to use the mouse to click on the image of the man you think most likely performed the behaviors(s) described.
^^When you are ready press the spacebar to begin.
</page>



<block blockpause>
/ preinstructions = (pause)
</block>

<page pause>
You have now completed a series of trials; there are four series in all.^^Feel free to pause for a moment and rest your eyes.^^When you are ready, press the spacebar to go on to the next set of trials.
</page>




*********************************
<picture faces1>
/ items = faces1
/ size = (35%, 35%)
</picture>

<item faces1>
/ 1 = "01.jpeg"
/ 2 = "02.jpeg"
/ 3 = "03.jpeg"
/ 4 = "04.jpg"
/ 5 = "05.jpeg"
/ 6 = "06.jpeg"
/ 7 = "07.jpeg"
/ 8 = "08.jpg"
/ 9 = "09.jpeg"
/ 10 = "10.jpeg"
/ 11 = "11.jpeg"
/ 12 = "12.jpeg"
/ 13 = "13.jpg"
/ 14 = "14.jpeg"
/ 15 = "15.jpeg"
/ 16 = "16.jpeg"
/ 17 = "17.jpeg"
/ 18 = "18.jpg"
/ 19 = "19.jpeg"
/ 20 = "20.jpeg"
/ 21 = "21.jpeg"
/ 22 = "22.jpeg"
/ 23 = "23.jpeg"
/ 24 = "24.jpeg"
/ 25 = "25.jpeg"
/ 26 = "26.jpeg"
/ 27 = "27.jpeg"
/ 28 = "28.jpg"
/ 29 = "29.jpg"
/ 30 = "30.jpg"
/ 31 = "31.jpg"
/ 32 = "32.jpg"
/ 33 = "33.jpg"
/ 34 = "34.jpg"
/ 35 = "35.jpg"
/ 36 = "36.jpeg"
/ 37 = "37.jpg"
/ 38 = "38.jpg"
/ 39 = "39.jpg"
/ 40 = "40.jpg"
/ 41 = "41.jpg"
/ 42 = "42.jpg"
/ 43 = "43.jpg"
/ 44 = "44.jpg"
/ 45 = "45.jpg"
/ 46 = "46.jpg"
/ 47 = "47.jpg"
/ 48 = "48.jpg"
/ 49 = "49.jpg"
/ 50 = "50.jpg"
</item>


<picture faces2>
/ items = faces2
/ size = (35%, 35%)
</picture>

<item faces2>
/ 1 = "51.jpg"
/ 2 = "52.jpg"
/ 3 = "53.jpg"
/ 4 = "54.jpg"
/ 5 = "55.jpg"
/ 6 = "56.jpg"
/ 7 = "57.jpg"
/ 8 = "58.jpg"
/ 9 = "59.jpg"
/ 10 = "60.jpg"
/ 11 = "61.jpg"
/ 12 = "62.jpg"
/ 13 = "63.jpg"
/ 14 = "64.jpg"
/ 15 = "65.jpg"
/ 16 = "66.jpg"
/ 17 = "67.jpg"
/ 18 = "68.jpg"
/ 19 = "69.jpg"
/ 20 = "70.jpg"
/ 21 = "71.jpg"
/ 22 = "72.jpg"
/ 23 = "73.jpg"
/ 24 = "74.jpg"
/ 25 = "75.jpg"
/ 26 = "76.jpg"
/ 27 = "77.jpg"
/ 28 = "78.jpg"
/ 29 = "79.jpg"
/ 30 = "80.jpg"
/ 31 = "81.jpg"
/ 32 = "82.jpg"
/ 33 = "83.jpg"
/ 34 = "84.jpg"
/ 35 = "85.jpg"
/ 36 = "86.jpg"
/ 37 = "87.jpg"
/ 38 = "88.jpg"
/ 39 = "89.jpg"
/ 40 = "90.jpg"
/ 41 = "91.jpg"
/ 42 = "92.jpg"
/ 43 = "93.jpg"
/ 44 = "94.jpg"
/ 45 = "95.jpg"
/ 46 = "96.jpg"
/ 47 = "97.jpg"
/ 48 = "98.jpg"
/ 49 = "99.jpg"
/ 50 = "100.jpg"
</item>

<likert vig1>
/ stimulusframes = [1=wallet, picture.faces1, picture.faces2]
/ anchors = [1="Person on your left"; 2="Person on your right"]
/ numpoints = 2
/ position = (50%, 80%)
/ anchorwidth = (15%)
</likert>

<likert vig2>
/ stimulusframes = [1=tie, picture.faces1, picture.faces1]
/ anchors = [1="Person on your left"; 2="Person on your right"]
/ numpoints = 2
/ position = (50%, 80%)
/ anchorwidth = (15%)
</likert>



<text wallet>
/ items = ("Vignette 1 goes here")
/ position = (50, 70)
</text>

<text tie>
/ items = ("Vignette 2 goes here")
/ position = (50, 70)
</text>


<radiobuttons gender>
/ caption = "Gender"
/ options = (
  "Female",
  "Male", "Prefer to self-describe")
</radiobuttons>

<radiobuttons race>
/ caption = "Race"
/ options = (
  "American Indian/Alaska Native",
  "East Asian",
  "South Asian",
  "Native Hawaian or other Pacific Islander",
  "Black or African American",
  "White",
  "More than one race - Black/White")
/ other = "Other"
</radiobuttons>


<textbox age>
/ caption = "Age"
/ mask = positiveinteger
/ range = (15, 70)
</textbox>


<block introinstr>
/ preinstructions = (introinstr1, introinstr2)
</block>

<block v1_wallet>
/ trials = [1-30=vig1]
/ postinstructions = (pause)
</block>

<block v2_tie>
/ trials = [1-30=vig2]
/ postinstructions = (pause)
</block>


<surveypage demographics1>
/ caption = "Please answer the following demographic questions"
/ fontstyle = ("Verdana", -16, true, false, false, false, 5, 0)
/ questions = [1=gender; 2=race; 3=age]
</surveypage>

<survey demographics>
/ pages = [1=demographics1]
/ recorddata = true
/ responsefontstyle = ("Verdana", -12, false, false, false, false, 5, 0)
/ itemfontstyle = ("Verdana", -13, false, false, false, false, 5, 0)
/ itemspacing = 2%
/ showpagenumbers = false
</survey>

<expt>
/ blocks = [1=introinstr; 2=noreplace(vig1, vig2); 3=blockpause; 4=noreplace(vig1, vig2); 5=demographics]
/ postinstructions = (end)
</expt>

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
shane - Monday, March 5, 2018
I have what is probably a relatively straightforward couple of snags for more experienced Inquisit users.  I have 80 images, 40 of category A and 40 of category B.  On a given trial I need to have two images presented on the screen, one beside the other, along with some text (below or above the images, doesn't really matter).  However, I need the images to come from the aforementioned different lists/categories such that one is always from category A and the other from category B.  I'd like the images to be randomly selected without replacement across the entire experiment (that is, Ps never see the same image twice). Further, I'd prefer the spatial arrangement of the images on the page be counterbalanced or at least randomized, such that cat A images aren't always on the left and cat B always on the right, for example. 

The text will remain the same in one block, but change in another block.  And the block orders should be randomized (vignette 1 and vignette 2). 

Lastly, if possible, I'd prefer participants make their selection (which is one of the two photos), by clicking on the photo, and I'd prefer to be able to assign that as correct or incorrect within inquisit but not displayed to participants. The code below is a mess, I know, but it should provide a start.  I'm very appreciative of any insight provided.  Best, Shane

<defaults >
/ screencolor = (255, 255, 255)
</defaults>

<instruct>
/ windowsize = (1000px, 800px)
/ nextkey = (" ")
/ prevkey = ("5")
/ fontstyle = ("Arial", 2.05%, false, false, false, false, 5, 0)
/ wait = 2000
</instruct>
*********************************************************
************ALL INSTRUCTIONS********************
**********************************************************

<page introinstr1>Welcome and thanks for your participation!^^Today you will be viewing a brief description of an act committed by one of two people pictured on the screen^^
You will use the mouse to respond to select which of the two you think was more likely the one who committed the act described.
^^There will be four sets of 20 photos each.^^Feel free to rest after each block if you like. The entire study should last no more than 20-25 minutes.^^Press the SPACEBAR to continue for more instructions.
</page>

<page introinstr2>As just described, you will be shown photos of two men at the same time on the screen, with a description of a behavior performed by one of the two, but NOT by both.
^^Only one of the men depicted behaved in the manner described.^^Your task is to use the mouse to click on the image of the man you think most likely performed the behaviors(s) described.
^^When you are ready press the spacebar to begin.
</page>



<block blockpause>
/ preinstructions = (pause)
</block>

<page pause>
You have now completed a series of trials; there are four series in all.^^Feel free to pause for a moment and rest your eyes.^^When you are ready, press the spacebar to go on to the next set of trials.
</page>




*********************************
<picture faces1>
/ items = faces1
/ size = (35%, 35%)
</picture>

<item faces1>
/ 1 = "01.jpeg"
/ 2 = "02.jpeg"
/ 3 = "03.jpeg"
/ 4 = "04.jpg"
/ 5 = "05.jpeg"
/ 6 = "06.jpeg"
/ 7 = "07.jpeg"
/ 8 = "08.jpg"
/ 9 = "09.jpeg"
/ 10 = "10.jpeg"
/ 11 = "11.jpeg"
/ 12 = "12.jpeg"
/ 13 = "13.jpg"
/ 14 = "14.jpeg"
/ 15 = "15.jpeg"
/ 16 = "16.jpeg"
/ 17 = "17.jpeg"
/ 18 = "18.jpg"
/ 19 = "19.jpeg"
/ 20 = "20.jpeg"
/ 21 = "21.jpeg"
/ 22 = "22.jpeg"
/ 23 = "23.jpeg"
/ 24 = "24.jpeg"
/ 25 = "25.jpeg"
/ 26 = "26.jpeg"
/ 27 = "27.jpeg"
/ 28 = "28.jpg"
/ 29 = "29.jpg"
/ 30 = "30.jpg"
/ 31 = "31.jpg"
/ 32 = "32.jpg"
/ 33 = "33.jpg"
/ 34 = "34.jpg"
/ 35 = "35.jpg"
/ 36 = "36.jpeg"
/ 37 = "37.jpg"
/ 38 = "38.jpg"
/ 39 = "39.jpg"
/ 40 = "40.jpg"
/ 41 = "41.jpg"
/ 42 = "42.jpg"
/ 43 = "43.jpg"
/ 44 = "44.jpg"
/ 45 = "45.jpg"
/ 46 = "46.jpg"
/ 47 = "47.jpg"
/ 48 = "48.jpg"
/ 49 = "49.jpg"
/ 50 = "50.jpg"
</item>


<picture faces2>
/ items = faces2
/ size = (35%, 35%)
</picture>

<item faces2>
/ 1 = "51.jpg"
/ 2 = "52.jpg"
/ 3 = "53.jpg"
/ 4 = "54.jpg"
/ 5 = "55.jpg"
/ 6 = "56.jpg"
/ 7 = "57.jpg"
/ 8 = "58.jpg"
/ 9 = "59.jpg"
/ 10 = "60.jpg"
/ 11 = "61.jpg"
/ 12 = "62.jpg"
/ 13 = "63.jpg"
/ 14 = "64.jpg"
/ 15 = "65.jpg"
/ 16 = "66.jpg"
/ 17 = "67.jpg"
/ 18 = "68.jpg"
/ 19 = "69.jpg"
/ 20 = "70.jpg"
/ 21 = "71.jpg"
/ 22 = "72.jpg"
/ 23 = "73.jpg"
/ 24 = "74.jpg"
/ 25 = "75.jpg"
/ 26 = "76.jpg"
/ 27 = "77.jpg"
/ 28 = "78.jpg"
/ 29 = "79.jpg"
/ 30 = "80.jpg"
/ 31 = "81.jpg"
/ 32 = "82.jpg"
/ 33 = "83.jpg"
/ 34 = "84.jpg"
/ 35 = "85.jpg"
/ 36 = "86.jpg"
/ 37 = "87.jpg"
/ 38 = "88.jpg"
/ 39 = "89.jpg"
/ 40 = "90.jpg"
/ 41 = "91.jpg"
/ 42 = "92.jpg"
/ 43 = "93.jpg"
/ 44 = "94.jpg"
/ 45 = "95.jpg"
/ 46 = "96.jpg"
/ 47 = "97.jpg"
/ 48 = "98.jpg"
/ 49 = "99.jpg"
/ 50 = "100.jpg"
</item>

<likert vig1>
/ stimulusframes = [1=wallet, picture.faces1, picture.faces2]
/ anchors = [1="Person on your left"; 2="Person on your right"]
/ numpoints = 2
/ position = (50%, 80%)
/ anchorwidth = (15%)
</likert>

<likert vig2>
/ stimulusframes = [1=tie, picture.faces1, picture.faces1]
/ anchors = [1="Person on your left"; 2="Person on your right"]
/ numpoints = 2
/ position = (50%, 80%)
/ anchorwidth = (15%)
</likert>



<text wallet>
/ items = ("Vignette 1 goes here")
/ position = (50, 70)
</text>

<text tie>
/ items = ("Vignette 2 goes here")
/ position = (50, 70)
</text>


<radiobuttons gender>
/ caption = "Gender"
/ options = (
  "Female",
  "Male", "Prefer to self-describe")
</radiobuttons>

<radiobuttons race>
/ caption = "Race"
/ options = (
  "American Indian/Alaska Native",
  "East Asian",
  "South Asian",
  "Native Hawaian or other Pacific Islander",
  "Black or African American",
  "White",
  "More than one race - Black/White")
/ other = "Other"
</radiobuttons>


<textbox age>
/ caption = "Age"
/ mask = positiveinteger
/ range = (15, 70)
</textbox>


<block introinstr>
/ preinstructions = (introinstr1, introinstr2)
</block>

<block v1_wallet>
/ trials = [1-30=vig1]
/ postinstructions = (pause)
</block>

<block v2_tie>
/ trials = [1-30=vig2]
/ postinstructions = (pause)
</block>


<surveypage demographics1>
/ caption = "Please answer the following demographic questions"
/ fontstyle = ("Verdana", -16, true, false, false, false, 5, 0)
/ questions = [1=gender; 2=race; 3=age]
</surveypage>

<survey demographics>
/ pages = [1=demographics1]
/ recorddata = true
/ responsefontstyle = ("Verdana", -12, false, false, false, false, 5, 0)
/ itemfontstyle = ("Verdana", -13, false, false, false, false, 5, 0)
/ itemspacing = 2%
/ showpagenumbers = false
</survey>

<expt>
/ blocks = [1=introinstr; 2=noreplace(vig1, vig2); 3=blockpause; 4=noreplace(vig1, vig2); 5=demographics]
/ postinstructions = (end)
</expt>

To randomize the order of the two blocks, you do

<expt>
/ blocks = [1=introinstr; 2,4=noreplace(vig1, vig2); 3=blockpause; 5=demographics]
/ postinstructions = (end)
</expt>

To keep the <picture> elements' selection pool intact across blocks, specify /resetinterval = 0 in both <picture> elements:

<picture faces1>
/ items = faces1
/ size = (35%, 35%)
/ resetinterval = 0
...
</picture>

<picture faces2>
/ items = faces2
/ size = (35%, 35%)
/ resetinterval = 0
...
</picture>

To randomize the <picture> elements on-screen positions, you can do

<picture faces1>
/ items = faces1
/ size = (35%, 35%)
/ resetinterval = 0
/ hposition = list.randomhpos.nextvalue
/ vposition = 50%

</picture>

<picture faces2>
/ items = faces2
/ size = (35%, 35%)
/ resetinterval = 0
/ hposition = list.randomhpos.nextvalue
/ vposition = 50%

</picture>

with

<list randomhpos>
/ items = (35%, 65%)
/ selectionrate = always
</list>

To have a click on one of the two images displayed be the response, you use standard <trial> elements instead of <likert>:

<trial vig1>
/ stimulusframes = [1=wallet, faces1, faces2]
/ inputdevice = mouse
/ validresponse = (faces1, faces2)
/ correctresponse = (faces1)
</trial>

You specify the object you want coded as the correct response in /correctresponse.

GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Reading This Topic

Explore
Messages
Mentions
Search