Presenting sentence and question sequentially on the same page

PennController for IBEX Forums Support Presenting sentence and question sequentially on the same page

Tagged: 

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #8331
    sangheekim
    Participant

    Hi Jeremy,

    I was wondering if there’s a way to present a target sentence and a question on the same page but sequentially, where the question appears only after participants’ keypress/click. I’d want to have the sentence remain on the same page when the question shows up. I’d also want to track (a) time duration before the keypress/click, and (b) the time duration after keypress/click (until the participant moves on to the next item). I’ve played around with the platform and with a number of elements I can think of, but I couldn’t get it to work.

    Thank you in advance for your help!

    Best,
    Sanghee

    #8332
    Jeremy
    Keymaster

    Hi Sanghee,

    How about this?

    newTrial(
      newText("target", "This is the target sentence").log().print()
      ,
      newKey("showQuestion", "").log().wait()
      ,
      newText("question", "Press F if the sentence is acceptable, J otherwise").log().print()
      ,
      newKey("answer", "FJ").log().wait()
    )

    Whenever you log a PennController element, the results line reports the timestamp of the event, so you can subtract the timestamp for the target sentence from the timestamp for the showQuestion Key element to calculate how fast the participant revealed the question, and subtract the timestamp for the question Text element from the timestamp for the answer Key element to calculate how fast they moved on to the next trial

    Jeremy

    #8333
    sangheekim
    Participant

    Hi Jeremy,

    Thanks for your help! I’ll try out with the code you suggested!

    Best,
    Sanghee

Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.