Millisecond Forums

Likert disable keyboard answer

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

By JuliaNo - 2/9/2017

I am asking people a question with the Likert option and have renamed the buttonvalues so they start with 0.
/ buttonvalues=[1="0"; 2="1"; 3="2"; 4="3"; 5="4"; 6="5"; 7="6"; 8="7"; 9="8"; 10="9"; 11="10"]

However, when people now use the keyboard and press 7, then the value 6 will be chosen, and this can be confusing and get wrong responses. I want to disable keyboard responses to solve this issue. How do I do that?
By Dave - 2/10/2017

JuliaNo - Friday, February 10, 2017
I am asking people a question with the Likert option and have renamed the buttonvalues so they start with 0.
/ buttonvalues=[1="0"; 2="1"; 3="2"; 4="3"; 5="4"; 6="5"; 7="6"; 8="7"; 9="8"; 10="9"; 11="10"]

However, when people now use the keyboard and press 7, then the value 6 will be chosen, and this can be confusing and get wrong responses. I want to disable keyboard responses to solve this issue. How do I do that?

It's not possible to disable the keyboard in <likert> elements, I'm afraid. What you can do, however, is build a "custom" likert scale using standard <text> and <trial> elements. This can be set up to only accept mouse input. Example:

<block myblock>
/ trials = [1-2=customlikert]
</block>

<trial customlikert>
/ stimulusframes = [1=line, 00, 01, 02, 03, 04, 05, 06, 07, 08, 09, 10, 11, leftanchor, rightanchor, question]
/ inputdevice = mouse
/ validresponse = (00, 01, 02, 03, 04, 05, 06, 07, 08, 09, 10, 11)
</trial>

<shape line>
/ shape = rectangle
/ color = black
/ size = (80%, 1%)
/ position = (50%, 70%)
</shape>

<text 00>
/ items = ("0")
/ txbgcolor = grey)
/ position = (10%, 70%)
/ size = (3%, 4%)
/ vjustify = center
</text>

<text 01>
/ items = ("1")
/ txbgcolor = grey)
/ position = (17.27%, 70%)
/ size = (3%, 4%)
/ vjustify = center
</text>

<text 02>
/ items = ("2")
/ txbgcolor = grey)
/ position = (24.54%, 70%)
/ size = (3%, 4%)
/ vjustify = center
</text>

<text 03>
/ items = ("3")
/ txbgcolor = grey)
/ position = (31.81%, 70%)
/ size = (3%, 4%)
/ vjustify = center
</text>

<text 04>
/ items = ("4")
/ txbgcolor = grey)
/ position = (39.08%, 70%)
/ size = (3%, 4%)
/ vjustify = center
</text>

<text 05>
/ items = ("5")
/ txbgcolor = grey)
/ position = (46.35%, 70%)
/ size = (3%, 4%)
/ vjustify = center
</text>

<text 06>
/ items = ("6")
/ txbgcolor = grey)
/ position = (53.62%, 70%)
/ size = (3%, 4%)
/ vjustify = center
</text>

<text 07>
/ items = ("7")
/ txbgcolor = grey)
/ position = (60.89%, 70%)
/ size = (3%, 4%)
/ vjustify = center
</text>

<text 08>
/ items = ("8")
/ txbgcolor = grey)
/ position = (68.16%, 70%)
/ size = (3%, 4%)
/ vjustify = center
</text>

<text 09>
/ items = ("9")
/ txbgcolor = grey)
/ position = (75.43%, 70%)
/ size = (3%, 4%)
/ vjustify = center
</text>

<text 10>
/ items = ("10")
/ txbgcolor = grey)
/ position = (82.7%, 70%)
/ size = (3%, 4%)
/ vjustify = center
</text>

<text 11>
/ items = ("11")
/ txbgcolor = grey)
/ position = (90%, 70%)
/ size = (3%, 4%)
/ vjustify = center
</text>

<text leftanchor>
/ items = ("Cold")
/ position = (10%, 65%)
</text>

<text rightanchor>
/ items = ("Hot")
/ position = (90%, 65%)
</text>

<text question>
/ items = ("Q1", "Q2")
</text>

By JuliaNo - 3/13/2017

Thank you, this worked. I now have a follow-up question:

People indicate their choice on this custom likert scale and I want to show another screen for a moment where they can see what they have chosen. So ideally, if they chose 3, they would see a second screen with the 3 highlighted for a second. My idea was to add an extra trial like this:

<block myblock>
/ trials = [1-18 = sequence(customlikert, customlikertFeedback)]
</block>

where the customlikertFeedback is the same as the customlikert (only that is has a timeout and requires no input), but the txbgcolor attribute would be changed for the choice that the participant made. Is that possible? Or would you have another idea how to provide this kind of feedback?
Thank!

By Dave - 3/13/2017

JuliaNo - Monday, March 13, 2017
Thank you, this worked. I now have a follow-up question:

People indicate their choice on this custom likert scale and I want to show another screen for a moment where they can see what they have chosen. So ideally, if they chose 3, they would see a second screen with the 3 highlighted for a second. My idea was to add an extra trial like this:

<block myblock>
/ trials = [1-18 = sequence(customlikert, customlikertFeedback)]
</block>

where the customlikertFeedback is the same as the customlikert (only that is has a timeout and requires no input), but the txbgcolor attribute would be changed for the choice that the participant made. Is that possible? Or would you have another idea how to provide this kind of feedback?
Thank!


Sure, you can do it like that.

<block myblock>
/ trials = [1-2=customlikert]
</block>

<trial customlikert>
/ stimulusframes = [1=line, 00, 01, 02, 03, 04, 05, 06, 07, 08, 09, 10, 11, leftanchor, rightanchor, question]
/ inputdevice = mouse
/ validresponse = (00, 01, 02, 03, 04, 05, 06, 07, 08, 09, 10, 11)
/ branch = [trial.customlikertfeedback]
</trial>

<trial customlikertfeedback>
/ ontrialbegin = [if (trial.customlikert.response == "00") text.00.textcolor = red;
    else if (trial.customlikert.response == "01") text.01.textbgcolor = blue;
    else if (trial.customlikert.response == "02") text.02.textbgcolor = blue;
    else if (trial.customlikert.response == "03") text.03.textbgcolor = blue;
    else if (trial.customlikert.response == "04") text.04.textbgcolor = blue;
    else if (trial.customlikert.response == "05") text.05.textbgcolor = blue;
    else if (trial.customlikert.response == "06") text.06.textbgcolor = blue;
    else if (trial.customlikert.response == "07") text.07.textbgcolor = blue;
    else if (trial.customlikert.response == "08") text.08.textbgcolor = blue;
    else if (trial.customlikert.response == "09") text.09.textbgcolor = blue;
    else if (trial.customlikert.response == "10") text.10.textbgcolor = blue;
    else if (trial.customlikert.response == "11") text.11.textbgcolor = blue;
]
/ ontrialend = [if (trial.customlikert.response == "00") text.00.textcolor = black;
    else if (trial.customlikert.response == "01") text.01.textbgcolor = grey;
    else if (trial.customlikert.response == "02") text.02.textbgcolor = grey;
    else if (trial.customlikert.response == "03") text.03.textbgcolor = grey;
    else if (trial.customlikert.response == "04") text.04.textbgcolor = grey;
    else if (trial.customlikert.response == "05") text.05.textbgcolor = grey;
    else if (trial.customlikert.response == "06") text.06.textbgcolor = grey;
    else if (trial.customlikert.response == "07") text.07.textbgcolor = grey;
    else if (trial.customlikert.response == "08") text.08.textbgcolor = grey;
    else if (trial.customlikert.response == "09") text.09.textbgcolor = grey;
    else if (trial.customlikert.response == "10") text.10.textbgcolor = grey;
    else if (trial.customlikert.response == "11") text.11.textbgcolor = grey;
]
/ stimulusframes = [1=line, 00, 01, 02, 03, 04, 05, 06, 07, 08, 09, 10, 11, leftanchor, rightanchor, question]
/ inputdevice = mouse
/ validresponse = (noresponse)
/ trialduration = 1000
/ recorddata = false
</trial>

<shape line>
/ shape = rectangle
/ color = black
/ size = (80%, 1%)
/ position = (50%, 70%)
/ erase = false
</shape>

<text 00>
/ items = ("0")
/ txbgcolor = grey)
/ position = (10%, 70%)
/ size = (3%, 4%)
/ vjustify = center
/ erase = false
</text>

<text 01>
/ items = ("1")
/ txbgcolor = grey)
/ position = (17.27%, 70%)
/ size = (3%, 4%)
/ vjustify = center
/ erase = false
</text>

<text 02>
/ items = ("2")
/ txbgcolor = grey)
/ position = (24.54%, 70%)
/ size = (3%, 4%)
/ vjustify = center
/ erase = false
</text>

<text 03>
/ items = ("3")
/ txbgcolor = grey)
/ position = (31.81%, 70%)
/ size = (3%, 4%)
/ vjustify = center
/ erase = false
</text>

<text 04>
/ items = ("4")
/ txbgcolor = grey)
/ position = (39.08%, 70%)
/ size = (3%, 4%)
/ vjustify = center
/ erase = false
</text>

<text 05>
/ items = ("5")
/ txbgcolor = grey)
/ position = (46.35%, 70%)
/ size = (3%, 4%)
/ vjustify = center
/ erase = false
</text>

<text 06>
/ items = ("6")
/ txbgcolor = grey)
/ position = (53.62%, 70%)
/ size = (3%, 4%)
/ vjustify = center
/ erase = false
</text>

<text 07>
/ items = ("7")
/ txbgcolor = grey)
/ position = (60.89%, 70%)
/ size = (3%, 4%)
/ vjustify = center
/ erase = false
</text>

<text 08>
/ items = ("8")
/ txbgcolor = grey)
/ position = (68.16%, 70%)
/ size = (3%, 4%)
/ vjustify = center
/ erase = false
</text>

<text 09>
/ items = ("9")
/ txbgcolor = grey)
/ position = (75.43%, 70%)
/ size = (3%, 4%)
/ vjustify = center
/ erase = false
</text>

<text 10>
/ items = ("10")
/ txbgcolor = grey)
/ position = (82.7%, 70%)
/ size = (3%, 4%)
/ vjustify = center
/ erase = false
</text>

<text 11>
/ items = ("11")
/ txbgcolor = grey)
/ position = (90%, 70%)
/ size = (3%, 4%)
/ vjustify = center
/ erase = false
</text>

<text leftanchor>
/ items = ("Cold")
/ position = (10%, 65%)
/ erase = false
</text>

<text rightanchor>
/ items = ("Hot")
/ position = (90%, 65%)
/ erase = false
</text>

<text question>
/ items = ("Q1", "Q2")
/ size = (50%, 20%)
/ erase = false
</text>