eventmask | R Documentation |
eventmask
is an internal function that takes sample data from
an EDF file and adds binary variables indicating whether blinks, fixations,
or saccades occurred for each trial
eventmask(EDFfile = NULL, samples = NULL, trials = NULL)
EDFfile |
path to an EDF file |
samples |
a data frame of sample data, resulting from |
trials |
(optional). Output from |
eventmask is called internally from edf.samples
, edf.trials
, and edf.all
to add 3 binary variables to sample data: fixation
, saccade
, and blink
. Each variable is coded
as 0 or 1 indicating the absence or presence of the fixation/saccade/blink for that sample. This is useful for quickly
indexing sample data based on events (for instance, removing pupil data during blinks). Eyelink (almost) always
records a saccade immediately before and after blinks, and those saccades are included as a part of the blink events.
A data frame of the same sample data, with the variables fixation
, saccade
, and blink
added
to the end.
Jason Hubbard, hubbard3@uoregon.edu
## Not run: #This is called internally, but if you want to use it manually: samples <- edf.samples('/path/to/file.edf') samples_with_mask <- eventmask('/path/to/file.edf',samples) #usually, you will use it in one of these ways: trials <- edf.trials('/path/to/file.edf',samples=T,eventmask=T) all <- edf.all('/path/to/file.edf',samples=T,eventmask=T) samps <- edf.samples('/path/to/file.edf',eventmask=T) ## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.