nearestPOI: Find the nearest Point of Interest for each fixation.

nearestPOIR Documentation

Find the nearest Point of Interest for each fixation.

Description

For each fixation in a fixation report, this function will determine the nearest Point of Interest and the fixation's distance from that Point of Interest.

Usage

nearestPOI(fixReport, poiList, supplement = TRUE)

Arguments

fixReport

A fixation Report as may be created by fixReport(). Must contain columns xpos and ypos.

poiList

A data.frame containing x,y coordinates for Points of Interest. The data.frame must contain exactly two columns, named xpos and ypos, in that order.

supplement

If TRUE, nearestPOI() will return a data.frame consisting of fixReport suplemented with columns nearestpoi and dist2poi. If FALSE return a 2 column data.frame with just those two columns.

Details

For each fixation in a fixation report, this function will determine the nearest Point of Interest and the fixation's distance from that Point of Interest.

The value of supplement determines whether to return the POI values within an enriched version of fixReport, or as a simple two column data.frame.

Value

A data.frame including columns nearestpoi and dist2poi.

Author(s)

Dave Braze <davebraze@gmail.com>


davebraze/FDBeye documentation built on April 28, 2022, 1:20 a.m.