Returns the same dataframe with new column indicating 0 (no fixation) and 1 (fixation) over time.

add_fixation2target(df, target, targetname = NULL)

Arguments

df

Eyetracker data frame. Expected column is `focus_object_raw`.

target

Unity's internal target name (e.g. as returned by `find_unity_threat_name`), or vector of target names

targetname

Optional suffix for the new column name (default: `fixation` without suffix)

Value

Eyetracker data frame with new column `fixation` or `fixation_targetname` added