factor_data: Convert variables to factor

Description Usage Arguments Note Author(s) Examples

Description

A convenience function to convert variables in the data to (ordered) factor variables, based on the type and values columns in the measurement model.

Usage

1
factor_data(srv, vars = NULL)

Arguments

srv

A survey object.

vars

The variables to convert. If NULL, variables specified as factor in the measurement model will be converted. Specify if you want to convert scale variables.

Note

See rescale_score and clean_score to convert scales from factor to numeric again.

Author(s)

Kristian D. Olsen

Examples

1
x %>% factor_data(vars = c("q1", "q17"))

itsdalmo/reporttool documentation built on May 18, 2019, 7:11 a.m.