row_expand_pattern: Expand row based on pattern

row_expand_patternR Documentation

Expand row based on pattern

Description

Expand row based on pattern

Usage

row_expand_pattern(dt, col_name, split_by_pattern, new_name)

Arguments

dt

input data table

col_name

column to be expanded

split_by_pattern

split based on pattern

new_name

new generated column name

Value

expanded data table

Examples

data("starwars_simple")
row_expand_pattern(starwars_simple, "films", ", ", "film")[]

dataMojo documentation built on March 7, 2023, 8:10 p.m.