1 | fixation_filter(file, xResolution = 1280, yResolution = 1024, xMM = 340, yMM = 270, agreementThreshold = 200, maxInterpolation = 75000, smoothingWindowSize = 3, smoothingMethod = "median", fixationMaxVelocity = 30)
|
file |
|
xResolution |
|
yResolution |
|
xMM |
|
yMM |
|
agreementThreshold |
|
maxInterpolation |
|
smoothingWindowSize |
|
smoothingMethod |
|
fixationMaxVelocity |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 | ##---- Should be DIRECTLY executable !! ----
##-- ==> Define data, use random,
##-- or do help(data=index) for the standard data sets.
## The function is currently defined as
function (file, xResolution = 1280, yResolution = 1024, xMM = 340,
yMM = 270, agreementThreshold = 200, maxInterpolation = 75000,
smoothingWindowSize = 3, smoothingMethod = "median", fixationMaxVelocity = 30)
{
data <- read.table(file, sep = ",", header = FALSE, strip.white = TRUE)
names(data) <- c("Timestamp", "ValidityLeft", "EyeLocXLeft",
"EyeLocYLeft", "EyeLocZLeft", "GazePointXLeft", "GazePointYLeft",
"ValidityRight", "EyeLocXRight", "EyeLocYRight", "EyeLocZRight",
"GazePointXRight", "GazePointYRight")
data <- eye_agreement(data, agreementThreshold, xResolution,
yResolution)
data <- eye_average(data)
data <- gaze_interpolation(data, maxInterpolation)
data <- gaze_smoothing(data, smoothingWindowSize, smoothingMethod)
data <- angular_velocity(data, xMM, yMM)
data <- fixation_classifier(data, fixationMaxVelocity)
return(data)
}
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.