mutate_lab_foreign: Mutate Wrapper for Foreign Labels

Description Usage Arguments Value Examples

Description

This mutate_lab_foreign wrapper function uses the mutate function from the dplyr to create a new column containing the foreign labels from a selected column.

Usage

1

Arguments

df

a data frame object to identify missing values

regex

a character string containing a regular expression to match a column or columns

column_name

the name of the specified column (uses standard evalulation typical of dplyr)

Value

Returns a data frame with a newly appended column contain the respective foreign labels from the haven package for each row based on the specified column.

Examples

1
mutate_lab_foreign(airquality, Solar.R) #throws error because no columns contain foreign labels

smh-ej/XploreR documentation built on May 13, 2019, 4:46 p.m.