quest: Pre-processing Questionnaire Data

Description Types of functions Abbreviations

Description

quest is a package for pre-processing questionnaire data to get it ready for statistical modeling. It contains functions for investigating missing data (e.g., rowNA), reshaping data (e.g., wide2long), validating responses (e.g., revalids), recoding variables (e.g., recodes), scoring (e.g., scores), centering (e.g., centers), aggregating (e.g., aggs), shifting (e.g., shifts), etc. Functions whose first phrases end with an s are vectorized versions of their functions without an s at the end of the first phrase. For example, center inputs a (atomic) vector and outputs a atomic vector to center and/or scale a single variable; centers inputs a data.frame and outputs a data.frame to center and/or scale multiple variables. Functions that end in _by are calculated by group. For example, center does grand-mean centering while center_by does group-mean centering. Putting the two together, centers_by inputs a data.frame and outputs a data.frame to center and/or scale multiple variables by group. Functions that end in _if are calculated dependent on the frequency of observed values (aka amount of missing data). The quest package uses the str2str package internally to convert R objects from one structure to another. See str2str for details.

Types of functions

There are two main types of functions. 1) Helper functions that primarily exist to save a few lines of code and are primarily for convenience (e.g., vecNA). 2) Functions for wrangling questionnaire data (e.g., nom2dum, reverses).

Abbreviations

See the table below

nm

names

ov

observed values

NA

missing values

prop

proportion

sep

separator

vrb

variable

grp

group

id

identifier

rtn

return

fun

function

dfm

data.frame

fct

factor

nom

nominal variable

dum

dummy variable

pomp

percentage of maximum possible

std

standardize

wth

within-groups

btw

between-groups


quest documentation built on Sept. 10, 2021, 5:07 p.m.

Related to quest in quest...