Comparing Labeled Text Elements Posted byglossaphile April 17, 2020 PennController for IBEX › Forums › Support › Comparing Labeled Text Elements This topic has 1 reply, 2 voices, and was last updated 5 years ago by Jeremy. Viewing 2 posts - 1 through 2 (of 2 total) Author Posts April 17, 2020 at 7:47 pm #5078 glossaphileParticipant Hi! For my lexical decision experiment, I’m trying to test if two labeled text elements (“Resp” and “Lex”) are identical and then have the browser display one of two different responses depending on whether they match. My best attempt is this: getText("Resp") .test.text(getText("Lex")) .success( newText("Correct!") .print() , newTimer(1000) .start() .wait() , getVar("Acc").set(1) ) .failure ( newText("Incorrect!") .print() , newTimer(1000) .start() .wait() , getVar("Acc").set(0) ) But this just returns “Incorrect!” for all trials regardless of whether the text elements match or not. I welcome any advice! April 17, 2020 at 9:42 pm #5079 JeremyKeymaster Hi! I don’t know why it’s not working, I’d have to double-check that. In the meantime, you can use a Var element as a proxy: newVar("RespVar"),newVar("LexVar") , getText("Resp").setVar("RespVar"), getText("Lex").setVar("LexVar") , getVar("RespVar") .test.is( getVar("LexVar") ) .success( newText("Correct!") .print() , newTimer(1000) .start() .wait() , getVar("Acc").set(1) ) .failure ( newText("Incorrect!") .print() , newTimer(1000) .start() .wait() , getVar("Acc").set(0) ) Jeremy Author Posts Viewing 2 posts - 1 through 2 (of 2 total) You must be logged in to reply to this topic. Log In Username: Password: Keep me signed in Log In