Learn R Programming

D3partitionR (version 0.5.0)

strip_path: Strip a dataframe containing a step into separate columns

Description

Strip a dataframe containing a step into separate columns

Usage

strip_path(data, path_col = "path", count_col = "count",
  value_cols = NULL, sep = "->")

Arguments

data

A dataframe containing the path.

path_col

Name of the column containing the path. The path should be a string of the format "step 1 -> step 2 -> step 3" .Default: "path"

count_col

Name of the column containing the number of occurences of the path. Default: "count"

value_cols

Names of the other columns to keep. Default: NULL

sep

String used to separate the different steps. Default: "->"

Value

A data.table with the columns specified in count_col, value_cols and one column per step in the path