saccade_VTI: Velocity threshold identification of saccades

View source: R/saccade_VTI.R

saccade_VTIR Documentation

Velocity threshold identification of saccades

Description

Use the velocity threshold algorithm from Salvucci & Goldberg (1996) to determine saccadic eye movements. Returns a summary of the saccades found per trial, including start and end coordinates, timing, duration, mean velocity, and peak velocity.

Usage

saccade_VTI(
  data,
  sample_rate = NULL,
  threshold = 150,
  min_dur = 20,
  participant_ID = "participant_ID"
)

Arguments

data

A dataframe with raw data (time, x, y, trial) for one participant

sample_rate

sample rate of the eye-tracker. If default of NULL, then it will be computed from the timestamp data and the number of samples

threshold

velocity threshold (degrees of VA / sec) to be used for identifying saccades

min_dur

minimum duration (ms) expected for saccades. This helps to avoid identification of very short saccades occurring at the boundary of velocity threshold

participant_ID

the variable that determines the participant identifier. If no column present, assumes a single participant

Details

It can take either single participant data or multiple participants where there is a variable for unique participant identification. The function looks for an identifier named participant_ID by default and will treat this as multiple-participant data as default, if not it is handled as single participant data, or the participant_ID needs to be specified

Value

a data frame giving the saccades found by trial

Examples

data <- combine_eyes(HCL)
saccade_VTI(data, participant_ID = "pNum")

tombeesley/eyetools documentation built on Dec. 23, 2024, 12:36 a.m.