row_expand_pattern {dataMojo}R 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")[]

[Package dataMojo version 1.0.0 Index]