Search the Legacy Support Archive (up to v2020)
  1. Read-only archive (2005–2024). Posting is closed. Need help with MediaLab or DirectRT 2027? Email service@empirisoft.com.

    All words · “exact phrase” · -leave out

    Advanced search

how to record RT while stimulus is ongoing (case 6715)

  1. #1

    how to record RT while stimulus is ongoing (case 6715)

    Hello All,

    Maybe this is an obvious one but I would like to start recording an RT during the middle of a stimulus. Here's the set-up:

    The stim consists of 9 images which total up to a cumulative 900msecs (there are 3 50msec images, 3 100msec images, and 3 150msec images- these are randomized within the 900 msec window).

    One of the images is a "trigger" which contains a target change that the participants are required to identify- I want the RT clock to start when this trigger image appears. Concurrent with the onset of this trigger image is a 60msec tone. The caveat is that there can be anywhere from 1 to 7 "distractor" images left to present after this trigger image is shown.

    I have my input file ignoring the images that come after the trigger image, asit is very unlikely that any participant will identify the target in the trigger image in the 100 to 600 (or so) msec before the remaining images are all displayed (not really relevant, but they need to press the "z" key if the target is a horizontal line, and the "m" key for a vertical target). I can accomplish this by subtraction, but think it would be super-nifty to learn how to actually make it work in DirectRT.

    I've included an excel sheet with examples- Thanks mucho mucho!

  2. #2
    Hi Zeke. I think I might be able to help you here, but I want to make sure I understand your design fully first. Do you want to have the images presented sequentially, with each appearing for it's specified period of time and then being replaced, or are you intending to add each subsequent image to the screen without removing the previous one? In other words, are your subjects going to be watching a sequence of images while they wait for the target, or is the screen going to get increasingly crowded with images until the target is presented, and then continue to fill up even after that? I just want to make sure I understand what you're going for before I make any suggestions.

    Best,
    Will

  3. #3
    The images are sequential. Each replaces the last with only the tone intervening (but that is layered over the image that it accompanies, i.e. the time=0).

  4. #4
    Hi Zeke,

    If I correctly understand what you want to do, you would like output in the form of how long passed between the appearance of your trigger image and whichever key the participant must press in response (the z key for a horizontal line target and the m key for the vertical line target). I got this idea from when you wrote in your original post that “the stim consists of 9 images.” If I’m interpreting this correctly, that means all we need to focus on is the key press participants must do in response to the trigger image. If so, that should be relatively straightforward.


    I modified the file you uploaded to reflect one way to do this. I took the second set of rows from the file you uploaded and modified them. The target image in this case is image2 because it is accompanied by the 60ms tone. The primary change is that I moved the values of “rt:44<13,50<14” to the stim value for image2. By doing this, the rt that gets recorded in short data file should be the amount of time that passes from the onset of image2 in this trial and when the key was pressed, which should be right in the "middle" (e.g., whenever the trigger image appears in the random order of all 9 images) of the entire stimuli set of 9 images.


    You may also have noticed that I changed the value of the style cell to 2 and added “,full” to the time cell in the stim2 trial. Your original post had stim 2 with a time value of 150ms. If you want to display the image for a certain amount of time and have participants press a key in response to the target, an easy way to accomplish this to create a new style line in the style file of your experiment with a MinMax value of 0-150. By using “,full” after defining the z and m response keys, stim2 will appear for 150ms no matter when the response key is pressed; instructions for this can be found in the Style Editor > Min Max – Setting RT Limits section of the DirectRT online help guide. Of course, you can match all of the other values in styles 1 and 2 of the style file so that all the images are presented in a similar manner except for the time onscreen.

    Please let me know if this is what you were looking for. If you need more help or something different, I’ll be happy to help you find your desired solution.

    Cheers!

    Psychboiler.

  5. #5
    Hi PsychBoiler

    "Full" huh? That's one I hadn't thought of but then I am still kind of a NOOB.
    Thanks for this fix! This should get the test up to running form.

    Thanks again for your help

  6. #6
    Hi Zeke,

    Happy to help! That's why the forums are here. I know that I got better with MediaLab and DirectRT the more I read and replied to threads on the website. So don't get too down on yourself. We all were beginners at some point, and I am still learning new things every time I visit here.

    As always, feel free to come back with any other questions or responses to other people's questions. We'll be here.

    Cheers!

    Psychboiler

  7. #7
    Hi Psychboiler,

    I don't like to take up your time, but I hope you can hold my hand a little bit longer-I've tried out the script you provided, and it doesn't allow RTs to be recorded on my system. Basically, DirectRT proceeds through all RTs when I have the "full" keyword included in the input file. I'm thinking there must be some environment variables that are different. Any ideas?

    Two other issues:
    1: significant screen flicker between images. Is there a way to completely suppress that? I've set the inter-trial interval to 0 msec (in style editor) but it has not resolved the issue.
    2: DirectRT will not play the .wav file that is necessary for one of the treaments. i really don't get why that would be.

    Kinda perplexing, but that's part of progress.

  8. #8
    Hi Zeke,

    Sorry that I have been away for a while, but I wanted to check in with you to see if you still needed help with this issue. If so, it would be great if you could send me the stimuli that you are using so that I can test it out for myself; the flickering issue is something I'd like to play with on my machine. You can upload your materials to the forum or send them to me at reed@empirisoft.com

    Cheers.

    Jason (formerly Psychboiler)