Millisecond Forums

Placing a text box below a picture

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

By Julie Krans - 3/25/2012

Hi,



I'm having trouble placing a textbox below a picture.


It works with a likert scale, but when I create a textbox instead I get an error that the trial reference cannot be located. I think this is because there is no stimulusframes in textbox?


Anyway, I need to present the pictures at random and only once, with one picture on the screen at once, and a textbox underneath.


I now have this:


----------------------------------------------------------------------------------
*** instruction BLUR1 ***
-----------------------------------------------------------------------------------
<page pBLUR>
You will now be presented with several pictures. It is your job to identify what's on the picture.^
Please type your answer in the box below the picture.^
If you cannot identify the picture, please write "don't know".^
^
</page>
----------------------------------------------------------------------
**** BLUR1 ****
----------------------------------------------------------------------
<picture BLUR>
/ items = BLUR
/ position = (50, 40)
</picture>

<item BLUR>
/1 = "airplane.jpg"
/2 = "baby.jpg"
/3 = "blackeye.jpg"
/4 = "bloodface.jpg"
/5 = "boxing.jpg"
/6 = "burning.jpg"
/7 = "carcrash.jpg"
/8 = "cattle.jpg"
/9 = "coma.jpg"
/10 = "earthquake.jpg"
/11 = "firefighter.jpg"
/12 = "gunshot.jpg"
/13 = "hanging.jpg"
/14 = "johndoe.jpg"
/15 = "rape.jpg"
/16 = "rebellion.jpg"
/17 = "running.jpg"
/18 = "thumb.jpg"
/19 = "trains.jpg"
/20 = "tumor.jpg"
/21 = "underwear.jpg"
</item>

<block BLUR1>
/ preinstructions = (pBLUR)
/ trials = [1-21 = BLUR]
</block>

Thanks for your help.

By Dave - 3/25/2012

There is no <trial> element named "BLUR" in the script you posted, hence the error message.


<block BLUR1>
/ preinstructions = (pBLUR)
/ trials = [1-21 = BLUR]
</block>


You should set up an <openended> element to collect the response and display the pictures.


Regards,


~Dave

By jolimie - 5/9/2012

Hi Dave, 



I have the same problem but I keep don't understand how to place a text box below a picture.


Thanks,




Mandy

By Dave - 5/9/2012

<openended myopenended>
/ stimulusframes = [1=mypicture}
[...]
/ position = (50%, 60%)
</openended>

<picture mypicture>
[...]
/ position = (50%, 40%)
</picture>


Generally, I recommend you work through the various tutorials in the Inquisit documentation before moving on.


Regards,


~Dave

By jolimie - 5/10/2012

Thanks Dave,



But I really try since 1 week, then I try your solution and I still don't be able to join a text box with a picture at the same time.



Mandy,


Ps: I'm french ;)

By Dave - 5/10/2012

Unless you can provide a way more specific description of your problems, I unfortunately don't see how I could help you at this point. In either case, I strongly recommend you (re-)work through the tutorials to get down the basics of Inquisit's syntax. Then read the documentation for the <picture> and <openended> elements and fill in the blanks in the example code I provided earlier.


If you'd rather work with <surveypage>s, first work through the "Demographic Survey" tutorial. Then see the documentation for <surveypage>, its /questions attribute, the <textbox> and the <image> element.


Regards,


~Dave

By jolimie - 5/10/2012

I want to have the same textbox but with different pictures. The subjects will have a picture an then will have to answer to the same question in the box. I have 16 pictures.




<picture Number>


/1 = "8.jpg"


/2 = "-14.jpg"


/3 = "52.jpg"


/4 = "-43.jpg"


/5 = "77.jpg"


/6 = "10.jpg"


/7 = "-8.jpg"


/8 = "-21.jpg"


/9 = "57.jpg"


/10 ="22.jpg"


/11= "62.jpg"


/12= "-50.jpg"


/13= "33.jpg"


/14= "-31.jpg"


/15= "-68.jpg"


/16= "-75.jpg"


</picture>





<textbox magnitude>


/ caption = "Magnitude numérique"


/ mask = positiveinteger


/ range = (7, 110)


</textbox>


By Dave - 5/10/2012

#1: Your definition / syntax for the <picture> element is wrong. You'll find correct examples in the respective documentation topics and tutorials.


#2: For a simple setup such as this one, use <openended> as outlined previously, not <textbox>. If, for whatever reason, you *must* use <textbox>, you'll have to define <surveypage> elements to *display* the <textbox> and picture. For that see the survey tutorial mentioned earlier. Use the <surveypage> element's /questions attribute to display an <image> or use its /stimulusframes attribute to display a <picture> element.

By jolimie - 5/10/2012

Hi,


This is really not simple for me. I read the part of openenden , item, picture, in the introduction. I tried the tutorials, and read some "how to". I can present the picture alone, and the text box alone but not together.



Mandy

By Dave - 5/10/2012

I tried the tutorials


I recommend you repeat that exercise. Don't just read or skim them -- *do* them., i.e., write the actual code by following the instructions closely. You'll see it's *really* simple:


<block MyBlock>
/ trials = [1-16=TypeNumber]
</block>

<openended TypeNumber>
/ stimulusframes = [1=NumberPicture]
/ position = (50%, 70%)
</openended>

<picture NumberPicture>
/ items = NumberItems
/ select = noreplace
/ position = (50%, 30%)
</picture>

<item NumberItems>
/1 = "8.jpg"
/2 = "-14.jpg"
/3 = "52.jpg"
/4 = "-43.jpg"
/5 = "77.jpg"
/6 = "10.jpg"
/7 = "-8.jpg"
/8 = "-21.jpg"
/9 = "57.jpg"
/10 ="22.jpg"
/11= "62.jpg"
/12= "-50.jpg"
/13= "33.jpg"
/14= "-31.jpg"
/15= "-68.jpg"
/16= "-75.jpg"
</item>


Regards,


~Dave

By jolimie - 5/13/2012

Hi,



I do this exercice, thank you. The box and the picture open but without the question, so I tried the "survey". And I have one problem :


I can't see all the pictures , why ?


Mandy,




**************************************************


PICTURE


**************************************************


<item NumberItems>


/1 = "8.jpg"


/2 = "-14.jpg"


/3 = "52.jpg"


/4 = "-43.jpg"


/5 = "77.jpg"


/6 = "10.jpg"


/7 = "-8.jpg"


/8 = "-21.jpg"


/9 = "57.jpg"


/10 ="22.jpg"


/11= "62.jpg"


/12= "-50.jpg"


/13= "33.jpg"


/14= "-31.jpg"


/15= "-68.jpg"


/16= "-75.jpg"


</item>



<picture NumberPicture>


/ items = NumberItems


/ select = noreplace


/ position = (50%, 50%)


</picture>





<textbox firstname>


/ caption = "Donnez la magnitude (valeur) du point :"


/ position = (50%,80%)


</textbox>



<surveypage demographics1>


/ fontstyle = ("Verdana", -16, true, false, false, false, 5, 0)


/ questions = [1=firstname] 


/ stimulusframes = [1-16=NumberPicture] 


</surveypage>



By Dave - 5/13/2012

You need to run the <surveypage> 16x via a <block> element's /trials attribute. You need to review the sections in the tutorials dealing with what a <trial> is and does, what a <block> is and does, etc.

By jolimie - 5/13/2012

I'm trying this, not yet found the solution.


Dure, dure.

By Dave - 5/13/2012

Dure, dure.


Actually, it's not that hard. You'll simply want to do


**************************************************
PICTURE
**************************************************
<item NumberItems>
/1 = "8.jpg"
/2 = "-14.jpg"
/3 = "52.jpg"
/4 = "-43.jpg"
/5 = "77.jpg"
/6 = "10.jpg"
/7 = "-8.jpg"
/8 = "-21.jpg"
/9 = "57.jpg"
/10 ="22.jpg"
/11= "62.jpg"
/12= "-50.jpg"
/13= "33.jpg"
/14= "-31.jpg"
/15= "-68.jpg"
/16= "-75.jpg"
</item>

<picture NumberPicture>
/ items = NumberItems
/ select = noreplace
/ position = (50%, 50%)
</picture>

<textbox typenumber>
/ caption = "Donnez la magnitude (valeur) du point :"
/ position = (50%,80%)
</textbox>

<surveypage numberpage>
/ fontstyle = ("Verdana", -16, true, false, false, false, 5, 0)
/ questions = [1=typenumber]
/ stimulusframes = [1=NumberPicture]
</surveypage>

<block numberblock>
/ trials = [1-16=numberpage]
</block>


Regards,


~Dave

By jolimie - 5/14/2012

Hi Dave,



Thank you very much for your help Dave. But, I have too much questions. I can not do that  all her by myself with the little time I have. Do you know another way to join 'Inquisit'. Are you a moderator? 



Mandy.

By Dave - 5/14/2012

Sorry, but I have no idea what your question is here.

By jolimie - 5/14/2012

I felt like I'm asking too much of your help.

By jolimie - 5/15/2012

I finally found the solution :



**************************************************


QUESTION 


**************************************************



<text sometext>


/ items = text


/ fontstyle = ("Academy Engraved LET", 2.12%, false, false, false, false, 5, 0)


/ txcolor = (0, 0, 0)


/ position = (50, 40)


</text>



<item text>


/1 = "Donnez la valeur du point situé sur ce segment :"


</item>


**************************************************


PICTURE


**************************************************


<picture NumberPicture>


/ items = NumberItems


/ select = noreplace


/ position = (50%, 30%)


</picture>



<item NumberItems>


/1 = "8.jpg"


/2 = "-14.jpg"


/3 = "52.jpg"


/4 = "-43.jpg"


/5 = "77.jpg"


/6 = "10.jpg"


/7 = "-8.jpg"


/8 = "-21.jpg"


/9 = "57.jpg"


/10 ="22.jpg"


/11= "62.jpg"


/12= "-50.jpg"


/13= "33.jpg"


/14= "-31.jpg"


/15= "-68.jpg"


/16= "-75.jpg"


</item>




**************************************************


BLOCKS


**************************************************


<block PictureQ> 


/ trials = [1-16=myopenended] 


</block>



**************************************************


AUTRES


**************************************************



<openended myopenended>


/ stimulusframes = [1=NumberPicture, sometext]


/ buttonlabel = "suivant"


</openended>



***********************************************************************


Data Columns


***********************************************************************



<data>


/ columns = [date, time, subject, stimulusitem, response]


</data>


Mandy,