MEAoutlier | R Documentation |
Sometimes motion energy analysis generates excessively high peaks resulting from video artifacts or other anomalies in the video source.
MEAoutlier( mea, threshold = function(x) { stats::sd(x) * 10 }, direction = c("greater", "less"), replace = NA )
mea |
an object of class |
threshold |
a numeric value, or a function returning the threshold value to consider data as outliers. |
direction |
a text string. One of " |
replace |
a numeric, NULL, or NA value to use as substitution. |
The same mea
object with all extreme values substituted.
## read the first 4 minutes of the normal sample ## (intake interviews of patients that carried on therapy) path_normal <- system.file("extdata/normal", package = "rMEA") mea_raw <- readMEA(path_normal, sampRate = 25, s1Col = 1, s2Col = 2, s1Name = "Patient", s2Name = "Therapist", idOrder = c("id","session"), idSep="_", skip=1, nrow = 6000) ## Remove extreme values, higher than 10 times the standard deviation mea_clean = MEAoutlier(mea_raw, threshold=function(x){sd(x)*10}, direction = "greater")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.