Learn R Programming

eyetrackingR

Recent Updates:

Note this is an active development (with permission) of the archived CRAN package eyetrackingR. The archived version is still available at https://github.com/jwdink/eyetrackingr

  • Warnings given by latest versions of dplyr and ggplot2 have been fixed.
  • Support for plotting predictions of binomial models using glmer, glmmTMB and glmmPQL

Eye-tracking Data: Cleaning, Analysis, & Visualization

This package is designed to make dealing with eye-tracking data easier. It addresses tasks along the pipeline from raw data to analysis and visualization. It offers several popular types of analyses, including growth-curve analysis, onset-contingent reaction time analyses, as well as several non-parametric bootstrapping approaches.

www.eyetracking-r.com

Installation

To install from CRAN:

install.packages('eyetrackingR')

To load:

library(eyetrackingR)

For the development version (make sure you have run install.packages("devtools") to get devtools first):

devtools::install_github("samhforbes/eyetrackingR")

Usage

EyetrackingR only requires that your data is in an R dataframe and has a few necessary columns. For that reason, eyetrackingR is compatible with any eyetracker, so long as you can export your data to a table and import it into R. See the preparing your data vignette.

Once your data is in R, you can prepare it for eyetrackingR by running the make_eyetrackingr_data function, e.g.:

data <- make_eyetrackingr_data(your_original_data, 
                       participant_column = "ParticipantName",
                       trial_column = "Trial",
                       time_column = "Timestamp",
                       trackloss_column = "TrackLoss",
                       treat_non_aoi_looks_as_missing = TRUE
)

From here, all of eyetrackingR's functionality becomes available for this data. Check out the eyetrackingR workflow to get an accesible overview of this functionality, or check out the vignettes for guides on how to clean your data, visualize it, and perform analyses.


Copyright (c) 2021, Samuel Forbes, Jacob Dink and Brock Ferguson

Released under the MIT License (see LICENSE for details)

Copy Link

Version

Install

install.packages('eyetrackingR')

Monthly Downloads

394

Version

0.2.1

License

MIT + file LICENSE

Maintainer

Samuel Forbes

Last Published

September 15th, 2023

Functions in eyetrackingR (0.2.1)

make_switch_data

Summarize data into time-to-switch from initial AOI.
make_onset_data

Make onset-contingent data.
plot.bin_analysis

Plot test-statistic for each time-bin in a time-series
make_time_window_data

Make a dataset collapsing over a time-window
plot.cluster_analysis

Visualize the results of a cluster analysis.
plot.eyetrackingR_data_summary

Plot some summarized data from eyetrackingR
plot.boot_splines_analysis

Plot differences in bootstrapped-splines data
plot.time_window_data

Plot a time-window dataset
print.cluster_analysis

Print Method for Cluster Analysis
plot.switch_data

Plot mean switch-from-initial-AOI times.
plot.onset_data

Plot onset-contingent data
summary.bin_analysis

Summary Method for Time-bin Analysis
subset_by_window

Extract a subset of the dataset within a time-window in each trial.
plot.boot_splines_data

Plot bootstrapped-splines data
summary.boot_splines_analysis

Summary Method for Bootstrapped Splines Analysis
summary.cluster_analysis

Summary Method for Cluster Analysis
simulate_eyetrackingr_data

Simulate an eyetrackingR dataset
reclass

Add the original class/attributes back onto result (usually of dplyr operation)
word_recognition

Data collected in an infant eyetracking study
plot.time_sequence_data

Plot time-sequence data
plot.time_cluster_data

Plot test-statistic for each time-bin in a time-series, highlight clusters. Plot time_cluster_data, highlights clusters of above-threshold time-bins.
summary.time_cluster_data

Summary Method for Cluster Analysis
trackloss_analysis

Analyze trackloss.
analyze_time_bins

analyze_time_bins()
clean_by_trackloss

Clean data by removing high-trackloss trials/subjects.
describe_data

Describe dataset
make_boot_splines_data

Bootstrap resample splines for time-series data.
make_eyetrackingr_data

Convert raw data for use in eyetrackingR
analyze_boot_splines

Estimate confidence intervals for bootstrapped splines data
eyetrackingR

eyetrackingR: A package for cleaning, analyzing, and visualizing eye-tracking datasets
get_time_clusters

Get information about the clusters in a cluster-analysis
add_aoi

Add an area-of-interest to your dataset, based on x-y coordinates and the AOI rectangle.
analyze_time_clusters

Bootstrap analysis of time-clusters.
make_time_sequence_data

make_time_sequence_data()
make_time_cluster_data

Make data for cluster analysis.