recodeReverse: Recode an ordered variable by reversing the codes.

Description Usage Arguments Details Value Author(s) See Also

View source: R/merge_utils.R

Description

Recode an ordered variable by reversing the codes.

Usage

1

Arguments

var

The variable containing the codes to be reversed.

Details

Given a variable of integer codes (e.g. measured on a Likert scale), or an ordered factor, this function will recode the variable with the codes reversed, and return the result.

Value

The recoded variable with codes reversed.

Author(s)

Ben Veal

See Also

recodeAs, recodeMatches, recodeVar, colwise2 for recoding multiple dataframe columns simultaneously (in library(plyr)).


vapniks/mergeutils documentation built on May 3, 2019, 4:33 p.m.