Selecting one stim or another at random

Home Forums Support Selecting one stim or another at random

  • This topic has 1 reply, 1 voice, and was last updated 8 years ago by Kellen.
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #8905
    ColleenH
    Guest

    Hi,

    I am trying to run a task where I display 2 images in one stim question where one of the images (e.g. 1A) is on the left and the other is on the right (e.g. 1B). However, I want to within participants whether the [A stim appear on the left and B on the right] or [B on the left and A on the right]. Each participant should only see each pair (e.g.pairs 1-10) once (random as to position for A and B). So I need to set up the QRT engine or javascript code to randomly select for each pair the version to use for that trial and then tell it not to use the other pair.

    Right now, I’ve set the url for the left stim in field 1 and the right stim in field 2. I’m wondering if it would make sense somehow to put one version in fields 1-2 and the other version in fields 3-4 and then somehow as the program to choose which 2 fields to present? Any ideas on how to do that?

    The response options are the same no matter the pair or version and there is no correct response. I would like to have a stim id column to tell me which version was presented but I think I can do that in the init question..

    #8906
    Kellen
    Guest

    I’m working on a task that has this format as well. I made two separate pages in the block: one where the Field 1 image is on the left and a second where the Field 1 image is on the right. Then I used display logic to display one or the other for each participant. I think there are a few ways to do the randomization and display logic, but I created an “embedded data” field in Survey Flow with ${rand://int/1:2} (which randomly assigns each person to 1 or 2) and then used display logic “if embedded data field = 1, display question” for each question on the first page, and “if embedded data field = 2, display question” for each question on the second page. Sorry this way is a bit messy, but I couldn’t think of any simpler way.

Viewing 2 posts - 1 through 2 (of 2 total)
  • The forum ‘Support’ is closed to new topics and replies.