romr.fnc {LMERConvenienceFunctions}R Documentation

Exclude outliers.

Description

Exclude outliers with a standardized residual at a distance greater than 2.5 standard deviations from 0. Note that this function cannot be used with generalized linear mixed-effects models (glmers).

Usage

romr.fnc(model, data, trim = 2.5)

Arguments

model

A mer object (fitted by function lmer). Note that this function cannot be used with generalized linear mixed-effects models (glmers).

data

The data frame on which the mer object was fitted.

trim

Threshold at which residuals will be removed. Defaults to 2.5 (standard deviations above and below the residuals mean).

Value

The function returns the following objects:

data

The data with outliers removed.

data0

The original data prior to removing the outliers.

n.removed

The number of data points removed.

percent.removed

The percentage of removed data points.

Author(s)

Antoine Tremblay, Statistics Canada, trea26@gmail.com, with contrbutions from Andy Flies, Michigan State University.

References

Baayen, R.H. (2008). Analyzing Linguistic Data. A Practical Introduction to Statistics Using R. Cambridge, UK: Cambridge University Press.

Newman, A.J., Tremblay, A., Nichols, E.S., Neville, H.J., and Ullman, M.T. (submitted). The Influence of Language Proficiency on Lexical-Semantic Processing in Native and Late Learners of English: ERP evidence. Submitted to the Journal of Cognitive Neuroscience.

Tremblay, A. and Tucker B. V. (submitted). What can the production of four-word sequences tell us about the mental lexicon? Submitted to The Mental Lexicon.

See Also

mcp.fnc perSubjectTrim.fnc

Examples

# see example in LMERConvenienceFunctions help page.

[Package LMERConvenienceFunctions version 3.0 Index]