unique_cause: get unique causes, regardless of the actual order in combo

View source: R/utils.R

unique_causeR Documentation

get unique causes, regardless of the actual order in combo

Description

get unique causes, regardless of the actual order in combo

Usage

unique_cause(cause_vec)

Arguments

cause_vec

a vector of characters with potential combo repetitions written in scrambled orders separated by "+"

Value

a vector of characters with unique meanings for latent causes

Examples

x <- c("A","B","A","CC+DD","DD+CC","E+F+G","B")
unique_cause(x)


zhenkewu/baker documentation built on March 17, 2022, 9:54 p.m.