Extract saccades using an algorithm proposed by Otero-Millan et al. (2014) tools:::Rd_expr_doi("10.1167/14.2.18")
method_om(x, y, vel, acc, sample_rate, trial, options)logical vector marking samples that belong to saccades
Gaze x coordinate, _arbitrary units_ as threshold velocity is computed in units of standard deviation.
Gaze x coordinate, _arbitrary units_ as threshold velocity is computed in units of standard deviation.
Velocity data.frame with columns x, y, amp.
Acceleration data.frame with columns x, y, amp.
Sample rate in Hz.
Trial id, so that trial borders are respected when computing velocity and saccades.
Named list with method options. See details for further information.
Method options, please refer to Otero-Millan et al. (2014) for details on parameters and the rationale for default values.
om_minimal_inter_peak_time_ms Minimal inter-peak interval in milliseconds. Defaults to 30.
om_maximal_peaks_per_second Maximal allowed number of peaks per second. Defaults to 5.
om_velocity_threshold_deg_per_sec Threshold saccade velocity in °/s. Defaults to 3.
om_pca_variance_threshold Minimal variance explained by retained rotated components. Defaults to 0.05.
extract_saccades
# Do not run this function directly, use extract_saccades() instead
Run the code above in your browser using DataLab