Fixation with temporal aspect

Mahdi Ramadan's Avatar

Mahdi Ramadan

03 Sep, 2019 07:27 PM

Hi Chris,

I am trying to figure out how to have the trigger for a fixation point have a temporal aspect. For example, I would like to have the trigger == 1 only if the fixation has passed a certain time ( for picking answer e.g.). Do you have an idea of a simple way to implement this in XML?

Thanks!

Mahdi

  1. Support Staff 1 Posted by Christopher Sta... on 03 Sep, 2019 08:14 PM

    Christopher Stawarz's Avatar

    Hi Mahdi,

    You can't change the behavior of a fixation point trigger. Instead, you'll need to modify your experiment to include some transition logic that takes the temporal condition into account.

    Typically, this is done by splitting the fixation portion of a trial into two states. The first state waits for fixation to begin, then transitions to the second state. The second state starts a timer. If fixation is broken before the timer expires, the experiment transitions to a failure state. Otherwise, it transitions to a success state. The following MWEL fragment demonstrates the basic structure:

    state 'Wait for fixation' {
        goto (
            target = 'Fixation'
            when = eye_in_window and (not saccade)
            )
    }
    
    state 'Fixation' {
        start_timer (
            timer = fixation_timer
            duration = fixation_duration
            )
    
        goto (
            target = 'Fixation failure'
            when = (not eye_in_window) and (not saccade)
            )
        goto (
            target = 'Fixation success'
            when = timer_expired(fixation_timer)
            )
    }
    

    This technique is used several times in the RSVPDemo experiment that's distributed with MWorks, so you may want to take a look at that, too.

    Cheers,
    Chris

  2. 2 Posted by Mahdi Ramadan on 04 Sep, 2019 04:01 PM

    Mahdi Ramadan's Avatar

    Ok thank you!

  3. Christopher Stawarz closed this discussion on 10 Sep, 2019 01:26 PM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac