Can I force a response?


Author
Message
Experimenter1
Experimenter1
Respected Member (499 reputation)Respected Member (499 reputation)Respected Member (499 reputation)Respected Member (499 reputation)Respected Member (499 reputation)Respected Member (499 reputation)Respected Member (499 reputation)Respected Member (499 reputation)Respected Member (499 reputation)
Group: Forum Members
Posts: 6, Visits: 15
Hello, I am trying to create multiple choice items and force a response in each item. Please note that I am not using the default radiobuttons element because I am trying to capture detailed interaction data (time-logged clicks) which I believe is not available with the default radiobuttons element.

Please see below for my code. The item allows moving on to the next without selecting any of the options. If anyone has any suggestions on how to force a response, I would greatly appreciate.
Just to be clear, all I want is to let the screen stay when a participant clicks Submit button without making a selection. I don't have to show any error message.

Thank you so much!


<block myblock>
/ trials = [1=MC1, clearscreen]
</block>

<trial MC1>
/ stimulusframes = [1=prompt1,option01_1,option02_1,option03_1,option04_1,option05_1,option06_1,submit]
/ inputdevice = mouse
/ validresponse = (option01_1,option02_1,option03_1,option04_1,option05_1,option06_1,submit)
/ ontrialend = [if(trial.MC1.response=="option01_1") {
  text.option01_1.textcolor=green;
  text.option02_1.textcolor=black;
  text.option03_1.textcolor=black;
  text.option04_1.textcolor=black;
  text.option05_1.textcolor=black;
  text.option06_1.textcolor=black;
}
]
/ ontrialend = [if(trial.MC1.response=="option02_1") {
  text.option01_1.textcolor=black;
  text.option02_1.textcolor=green;
  text.option03_1.textcolor=black;
  text.option04_1.textcolor=black;
  text.option05_1.textcolor=black;
  text.option06_1.textcolor=black;
}
]
/ ontrialend = [if(trial.MC1.response=="option03_1") {
  text.option01_1.textcolor=black;
  text.option02_1.textcolor=black;
  text.option03_1.textcolor=green;
  text.option04_1.textcolor=black;
  text.option05_1.textcolor=black;
  text.option06_1.textcolor=black;
}
]
/ ontrialend = [if(trial.MC1.response=="option04_1") {
  text.option01_1.textcolor=black;
  text.option02_1.textcolor=black;
  text.option03_1.textcolor=black;
  text.option04_1.textcolor=green;
  text.option05_1.textcolor=black;
  text.option06_1.textcolor=black;
}
]
/ ontrialend = [if(trial.MC1.response=="option05_1") {
  text.option01_1.textcolor=black;
  text.option02_1.textcolor=black;
  text.option03_1.textcolor=black;
  text.option04_1.textcolor=black;
  text.option05_1.textcolor=green;
  text.option06_1.textcolor=black;
}
]
/ ontrialend = [if(trial.MC1.response=="option06_1") {
  text.option01_1.textcolor=black;
  text.option02_1.textcolor=black;
  text.option03_1.textcolor=black;
  text.option04_1.textcolor=black;
  text.option05_1.textcolor=black;
  text.option06_1.textcolor=green;
}
]
/ branch = [if(trial.MC1.response!="submit")trial.MC1]
</trial>


<text prompt1>
/ items = ("ITEM TEXT")
/ fontstyle= ("Calibri", 3%, true, false, false, false, 5, 1)
/ position = (10%, 30%)
/ halign = left
</text>

<text option01_1>
/ items = ("A. TEXT")
/ txcolor = black
/ position = (15%,44%)
/ hjustify = left
/ halign = left
</text>

<text option02_1>
/ items = ("B. TEXT")
/ txcolor = black
/ position = (15%,49%)
/ hjustify = left
/ halign = left
</text>

<text option03_1>
/ items = ("C. TEXT")
/ txcolor = black
/ position = (15%,54%)
/ hjustify = left
/ halign = left
</text>

<text option04_1>
/ items = ("D. TEXT")
/ txcolor = black
/ position = (15%,59%)
/ hjustify = left
/ halign = left
</text>


<text option05_1>
/ items = ("E. TEXT")
/ width = 100%
/ txcolor = black
/ position = (15%,64%)
/ hjustify = left
/ halign = left
</text>

<text option06_1>
/ items = ("F. TEXT.")
/ txcolor = black
/ position = (15%,69%)
/ hjustify = left
/ halign = left
</text>

<text submit>
/ items = ("Submit")
/ txbgcolor = grey
/ hjustify = center
/ vjustify = center
/ position = (50%, 90%)
/ size = (20%, 10%)
/ erase = false
</text>

<shape clearscreen>
/ color = white
/ shape = rectangle
/ size = (100%, 100%)
</shape>

<trial clearscreen>
/ stimulusframes = [1=clearscreen]
/ trialduration = 200
/ validresponse = (0)
</trial>


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
Experimenter1 - Thursday, September 13, 2018
Hello, I am trying to create multiple choice items and force a response in each item. Please note that I am not using the default radiobuttons element because I am trying to capture detailed interaction data (time-logged clicks) which I believe is not available with the default radiobuttons element.

Please see below for my code. The item allows moving on to the next without selecting any of the options. If anyone has any suggestions on how to force a response, I would greatly appreciate.
Just to be clear, all I want is to let the screen stay when a participant clicks Submit button without making a selection. I don't have to show any error message.

Thank you so much!


<block myblock>
/ trials = [1=MC1, clearscreen]
</block>

<trial MC1>
/ stimulusframes = [1=prompt1,option01_1,option02_1,option03_1,option04_1,option05_1,option06_1,submit]
/ inputdevice = mouse
/ validresponse = (option01_1,option02_1,option03_1,option04_1,option05_1,option06_1,submit)
/ ontrialend = [if(trial.MC1.response=="option01_1") {
  text.option01_1.textcolor=green;
  text.option02_1.textcolor=black;
  text.option03_1.textcolor=black;
  text.option04_1.textcolor=black;
  text.option05_1.textcolor=black;
  text.option06_1.textcolor=black;
}
]
/ ontrialend = [if(trial.MC1.response=="option02_1") {
  text.option01_1.textcolor=black;
  text.option02_1.textcolor=green;
  text.option03_1.textcolor=black;
  text.option04_1.textcolor=black;
  text.option05_1.textcolor=black;
  text.option06_1.textcolor=black;
}
]
/ ontrialend = [if(trial.MC1.response=="option03_1") {
  text.option01_1.textcolor=black;
  text.option02_1.textcolor=black;
  text.option03_1.textcolor=green;
  text.option04_1.textcolor=black;
  text.option05_1.textcolor=black;
  text.option06_1.textcolor=black;
}
]
/ ontrialend = [if(trial.MC1.response=="option04_1") {
  text.option01_1.textcolor=black;
  text.option02_1.textcolor=black;
  text.option03_1.textcolor=black;
  text.option04_1.textcolor=green;
  text.option05_1.textcolor=black;
  text.option06_1.textcolor=black;
}
]
/ ontrialend = [if(trial.MC1.response=="option05_1") {
  text.option01_1.textcolor=black;
  text.option02_1.textcolor=black;
  text.option03_1.textcolor=black;
  text.option04_1.textcolor=black;
  text.option05_1.textcolor=green;
  text.option06_1.textcolor=black;
}
]
/ ontrialend = [if(trial.MC1.response=="option06_1") {
  text.option01_1.textcolor=black;
  text.option02_1.textcolor=black;
  text.option03_1.textcolor=black;
  text.option04_1.textcolor=black;
  text.option05_1.textcolor=black;
  text.option06_1.textcolor=green;
}
]
/ branch = [if(trial.MC1.response!="submit")trial.MC1]
</trial>


<text prompt1>
/ items = ("ITEM TEXT")
/ fontstyle= ("Calibri", 3%, true, false, false, false, 5, 1)
/ position = (10%, 30%)
/ halign = left
</text>

<text option01_1>
/ items = ("A. TEXT")
/ txcolor = black
/ position = (15%,44%)
/ hjustify = left
/ halign = left
</text>

<text option02_1>
/ items = ("B. TEXT")
/ txcolor = black
/ position = (15%,49%)
/ hjustify = left
/ halign = left
</text>

<text option03_1>
/ items = ("C. TEXT")
/ txcolor = black
/ position = (15%,54%)
/ hjustify = left
/ halign = left
</text>

<text option04_1>
/ items = ("D. TEXT")
/ txcolor = black
/ position = (15%,59%)
/ hjustify = left
/ halign = left
</text>


<text option05_1>
/ items = ("E. TEXT")
/ width = 100%
/ txcolor = black
/ position = (15%,64%)
/ hjustify = left
/ halign = left
</text>

<text option06_1>
/ items = ("F. TEXT.")
/ txcolor = black
/ position = (15%,69%)
/ hjustify = left
/ halign = left
</text>

<text submit>
/ items = ("Submit")
/ txbgcolor = grey
/ hjustify = center
/ vjustify = center
/ position = (50%, 90%)
/ size = (20%, 10%)
/ erase = false
</text>

<shape clearscreen>
/ color = white
/ shape = rectangle
/ size = (100%, 100%)
</shape>

<trial clearscreen>
/ stimulusframes = [1=clearscreen]
/ trialduration = 200
/ validresponse = (0)
</trial>


Yes, you can force a response by making the "submit" response invalid for the 1st instance of the trial per /isvalidresponse:

<block myblock>
/ trials = [1=MC1, clearscreen]
</block>

<values>
/ mc1count = 0
</values>

<trial MC1>
/ ontrialbegin = [
    values.mc1count += 1;
]

/ stimulusframes = [1=prompt1,option01_1,option02_1,option03_1,option04_1,option05_1,option06_1,submit]
/ inputdevice = mouse
/ validresponse = (option01_1,option02_1,option03_1,option04_1,option05_1,option06_1, submit)
/ isvalidresponse = [
    (trial.MC1.response == "submit" && values.mc1count > 1) ||
    trial.MC1.response == "option01_1" ||
    trial.MC1.response == "option02_1" ||
    trial.MC1.response == "option03_1" ||
    trial.MC1.response == "option04_1" ||
    trial.MC1.response == "option05_1" ||
    trial.MC1.response == "option06_1"
]

/ ontrialend = [if(trial.MC1.response=="option01_1") {
  text.option01_1.textcolor=green;
  text.option02_1.textcolor=black;
  text.option03_1.textcolor=black;
  text.option04_1.textcolor=black;
  text.option05_1.textcolor=black;
  text.option06_1.textcolor=black;
}
]
/ ontrialend = [if(trial.MC1.response=="option02_1") {
  text.option01_1.textcolor=black;
  text.option02_1.textcolor=green;
  text.option03_1.textcolor=black;
  text.option04_1.textcolor=black;
  text.option05_1.textcolor=black;
  text.option06_1.textcolor=black;
}
]
/ ontrialend = [if(trial.MC1.response=="option03_1") {
  text.option01_1.textcolor=black;
  text.option02_1.textcolor=black;
  text.option03_1.textcolor=green;
  text.option04_1.textcolor=black;
  text.option05_1.textcolor=black;
  text.option06_1.textcolor=black;
}
]
/ ontrialend = [if(trial.MC1.response=="option04_1") {
  text.option01_1.textcolor=black;
  text.option02_1.textcolor=black;
  text.option03_1.textcolor=black;
  text.option04_1.textcolor=green;
  text.option05_1.textcolor=black;
  text.option06_1.textcolor=black;
}
]
/ ontrialend = [if(trial.MC1.response=="option05_1") {
  text.option01_1.textcolor=black;
  text.option02_1.textcolor=black;
  text.option03_1.textcolor=black;
  text.option04_1.textcolor=black;
  text.option05_1.textcolor=green;
  text.option06_1.textcolor=black;
}
]
/ ontrialend = [if(trial.MC1.response=="option06_1") {
  text.option01_1.textcolor=black;
  text.option02_1.textcolor=black;
  text.option03_1.textcolor=black;
  text.option04_1.textcolor=black;
  text.option05_1.textcolor=black;
  text.option06_1.textcolor=green;
}
]
/ branch = [if(trial.MC1.response!="submit")trial.MC1]
</trial>


<text prompt1>
/ items = ("ITEM TEXT")
/ fontstyle= ("Calibri", 3%, true, false, false, false, 5, 1)
/ position = (10%, 30%)
/ halign = left
</text>

<text option01_1>
/ items = ("A. TEXT")
/ txcolor = black
/ position = (15%,44%)
/ hjustify = left
/ halign = left
</text>

<text option02_1>
/ items = ("B. TEXT")
/ txcolor = black
/ position = (15%,49%)
/ hjustify = left
/ halign = left
</text>

<text option03_1>
/ items = ("C. TEXT")
/ txcolor = black
/ position = (15%,54%)
/ hjustify = left
/ halign = left
</text>

<text option04_1>
/ items = ("D. TEXT")
/ txcolor = black
/ position = (15%,59%)
/ hjustify = left
/ halign = left
</text>


<text option05_1>
/ items = ("E. TEXT")
/ width = 100%
/ txcolor = black
/ position = (15%,64%)
/ hjustify = left
/ halign = left
</text>

<text option06_1>
/ items = ("F. TEXT.")
/ txcolor = black
/ position = (15%,69%)
/ hjustify = left
/ halign = left
</text>

<text submit>
/ items = ("Submit")
/ txbgcolor = grey
/ hjustify = center
/ vjustify = center
/ position = (50%, 90%)
/ size = (20%, 10%)
/ erase = false
</text>

<shape clearscreen>
/ color = white
/ shape = rectangle
/ size = (100%, 100%)
</shape>

<trial clearscreen>
/ stimulusframes = [1=clearscreen]
/ trialduration = 200
/ validresponse = (0)
</trial>

Experimenter1
Experimenter1
Respected Member (499 reputation)Respected Member (499 reputation)Respected Member (499 reputation)Respected Member (499 reputation)Respected Member (499 reputation)Respected Member (499 reputation)Respected Member (499 reputation)Respected Member (499 reputation)Respected Member (499 reputation)
Group: Forum Members
Posts: 6, Visits: 15
It worked! Thank you so much, Dave!!! 
GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Reading This Topic

Explore
Messages
Mentions
Search