PennController for IBEX › Forums › Support › Keeping track of participant accuracy › Reply To: Keeping track of participant accuracy
August 12, 2020 at 12:51 pm
#5974
Keymaster
Hi,
You are using a plain javascript ternary conditionals where you should be using a PennController test command. I briefly explain this point below the code in this message.
Your trial should look like this:
newTrial("feedback",
newVar("Acc", 0.8).global()
,
newText("low_acc", "Low accuracy")
,
newText("high_acc", "High accuracy")
,
getVar("Acc").test.is( v => v > 0.5 )
.success( getText("high_acc").print() )
.failure( getText("low_acc").print() )
,
newButton("Exit")
.center()
.print()
.wait()
)
Jeremy