invert_named: Invert a named vector

View source: R/invert-named.R

invert_namedR Documentation

Invert a named vector

Description

Invert the names and elements of a vector, useful when using named vectors as the abbreviation arguments both of expand_abbrev() and abbrev_full() (or their parent normalization functions like normal_address())

Usage

invert_named(x)

Arguments

x

A named vector.

Value

A named vector with names in place of elements and vice versa.

Examples

invert_named(x = c("name" = "element"))

irworkshop/campfin documentation built on Oct. 19, 2023, 8:02 a.m.