simple_lab: Simplify labels (, or all vectors)

View source: R/translate.R

simple_labR Documentation

Simplify labels (, or all vectors)

Description

Split based on a pattern and includes selected parts

Usage

simple_lab(x, parts = 1, pattern = ", ")

Arguments

x

A vector to simplify.

parts

A position of parts to include. Default 1.

pattern

A ", " Pattern to look for.

Examples

simple_lab(c(nulc = "unit labour cost, nominal"), parts = 1)
simple_lab(x = c(nulc = "unit labour cost, nominal", nulc_va = "unit labour cost, nominal, value added"), parts = c(2,3))
simple_lab(x = as.factor(c(nulc = "unit labour cost, nominal", nulc_va = "unit labour cost, nominal, value added")), parts = c(2,3))
simple_lab(var_labels_fi[c(36:41)], parts = c(3,4))


pttry/ficomp documentation built on June 11, 2024, 9:53 p.m.