Learn R Programming

ufs (version 0.5.12)

carelessReport: A report to help diagnosing careless responders

Description

This function wraps functions from the careless package to help inspect and diagnose careless participants. It is optimized for using in R Markdown files.

Usage

carelessReport(
  data,
  items = names(data),
  nFlags = 1,
  flagUnivar = 0.99,
  flagMultivar = 0.95,
  irvSplit = 4,
  headingLevel = 3,
  datasetName = NULL,
  responseTime = NULL,
  headingSuffix = " {.tabset}",
  digits = 2,
  missingSymbol = "Missing"
)

Value

NULL, invisibly; and prints the report.

Arguments

data

The dataframe.

items

The items to look at.

nFlags

How many indicators need to be flagged for a participant to be considered suspect.

flagUnivar

How extreme a score has to be for it to be flagged as suspicous univariately.

flagMultivar

This has not been implemented yet.

irvSplit

Whether to split for the IRV, and if so, in how many parts.

headingLevel

The level of the heading in Markdown (the number of #s to include before the heading).

datasetName

The name of the dataset to display (to override, if desired).

responseTime

If not NULL, the name of a column containing the participants' response times.

headingSuffix

The suffix to include; by default, set such that the individual participants IRP plots are placed in separate tabs.

digits

The number of digits to round to.

missingSymbol

How to represent missing values.

Examples

Run this code
### Get the BFI data taken from the `psych` package
dat <- ufs::bfi;

### Get the variable names for the regular items
bfiVars <-
  setdiff(names(dat),
          c("gender", "education", "age"));

### Inspect suspect participants, very conservatively to
### limit the output (these are 2800 participants).
carelessReport(data = dat,
               items = bfiVars,
               nFlags = 5);

Run the code above in your browser using DataLab