match_ir: Match Two Items From Data Frame

Description Usage Arguments Value Examples

View source: R/padis_specific_functions.R

Description

This function matches two items from a data frame data by looking for their common stem (var_stem), and the pattern at the end that makes each variable name unique (end_pattern). The function is mainly used in imaginer.

Usage

1
match_ir(data, var_stem, end_pattern = c(".r", ".i"))

Arguments

data

The data frame in which the variables should be found

var_stem

The stem of the items, i.e. what both item-names share

end_pattern

The pattern at the end of the variable that makes both variables unique

Value

A vector of length 2 with the two identified variables names

Examples

1
2
data <- imaginer_example_data
match_ir(data, "PSP1.variable", c(".r", ".i"))

kthorstmann/padis documentation built on May 24, 2019, 5:01 a.m.