Split wrangles, with recipe examples, parameters, and behavior.
Explode
Explode a column of lists into rows.
Explode a column of lists into rows
Parameters
| Name | Description | Accepted Values | Default | Required |
|---|
| I/O | | | | |
input | Name of the column(s) to explode. If multiple columns are included they must contain lists of the same length. | string, integer, array | — | Yes |
| Options | | | | |
drop_empty | If true, any rows that contain an empty list will be dropped. If false, rows that contain empty lists will keep 1 row with an empty value. Default False. | boolean | false | No |
| Formatting | | | | |
reset_index | Reset the index after exploding. Default True. | boolean | true | No |
| Conditions | | | | |
if | Condition that determines whether the wrangle runs as a whole. Recipe variables may be referenced with ${variable}. | string | — | No |
where | Filter rows before applying the wrangle using SQL-like criteria, such as column1 = 123 OR column2 = 'abc'. | string | — | No |
where_params | Values used with where for parameterized criteria. Uses SQLite placeholder syntax such as ? or :name. | array, object | — | No |
Examples
wrangles:
- explode:
input: Products
| Products | Manufacturer |
|---|
| Ball Bearing | SKF |
| Bearing Seal | SKF |
| Angle Grinder | Milwaukee |
| Drill | Milwaukee |
| Impact Driver | Milwaukee |
| Solid State Relay | Schneider |
Access
| Requirement | Value |
|---|
| AI-powered | No |
| Requires WrangleWorks account | No |
| Requires subscription | No |
| Requires external API key | No |
Technical details
| Field | Value |
|---|
| Catalog ID | 77 |
| Catalog key | explode |
| Recipe key | explode |
| Catalog status | active |
| Lifecycle status | active |
| Recipe Writer eligible | Yes |
| Namespace | Root-level |
| Documentation group | split |
| Aliases | None |
| Runtime symbol | wrangles.recipe_wrangles.pandas.explode |
| Legacy UUID | 4e4b13ac-8d50-4b2c-85c8-2c31de1e817d |
Sources
Dictionary
Split one or more dictionaries into columns. The dictionary keys will be returned as the new column headers. If the dictionaries contain overlapping values, the last value will be returned.
Split a dictionary into columns. The dictionary keys are used as the new column headers.
Parameters
| Name | Description | Accepted Values | Default | Required |
|---|
| I/O | | | | |
input | Name or lists of the column(s) containing dictionaries to be split. If providing multiple dictionaries and the dictionaries contain overlapping values, the last value will be returned. | string, integer, array | — | Yes |
output | In columns output_format, this is an optional subset of keys to extract from the dictionary. If not provided, all keys will be returned. Columns can be renamed with the following syntax: output: - key1: new_column_name1 - key2: new_column_name2 In to_lists output_format, this must be two output columns for the keys and values lists. If not provided, Keys and Values will be used. | string, array, null | null | No |
| Formatting | | | | |
output_format | How to split the dictionary. columns creates one output column for each dictionary key. to_lists creates two output columns containing lists of keys and values. | string; one of: | "columns" | No |
| Conditions | | | | |
if | Condition that determines whether the wrangle runs as a whole. Recipe variables may be referenced with ${variable}. | string | — | No |
where | Filter rows before applying the wrangle using SQL-like criteria, such as column1 = 123 OR column2 = 'abc'. | string | — | No |
where_params | Values used with where for parameterized criteria. Uses SQLite placeholder syntax such as ? or :name. | array, object | — | No |
| Errors | | | | |
default | Provide a set of default headings and values if they are not found within the input. | object, null | null | No |
Examples
wrangles:
- split.dictionary:
input: Column
wrangles:
- split.dictionary:
input: Column
output: Col2
wrangles:
- split.dictionary:
input: Column
output: Col*
wrangles:
- split.dictionary:
input: Column
output: "regex: .*3"
wrangles:
- split.dictionary:
input: Column
output:
- Col1: Column 1
- Col2: Column 2
wrangles:
- split.dictionary:
input: Column
output:
- Col*: Column *
| Column 1 | Column 2 | Column 3 |
|---|
| A | B | C |
Access
| Requirement | Value |
|---|
| AI-powered | No |
| Requires WrangleWorks account | No |
| Requires subscription | No |
| Requires external API key | No |
Technical details
| Field | Value |
|---|
| Catalog ID | 63 |
| Catalog key | split.dictionary |
| Recipe key | split.dictionary |
| Catalog status | active |
| Lifecycle status | active |
| Recipe Writer eligible | Yes |
| Namespace | split |
| Documentation group | split |
| Aliases | None |
| Runtime symbol | wrangles.recipe_wrangles.split.dictionary |
| Legacy UUID | 06ca98e4-d026-43f7-84eb-af246d401ba9 |
Sources
List
Split a list in a single column to multiple columns.
Split a list into multiple columns. If only one output is given, split.list returns the same list it was given, so output should be a list of columns or a column name with a wildcard (*).
Parameters
| Name | Description | Accepted Values | Default | Required |
|---|
| I/O | | | | |
input | Name of the column to be split. | string, integer | — | Yes |
output | Name of column(s) for the results. If providing a single column, use a wildcard (*) to indicate a incrementing integer. | string, array | — | Yes |
| Conditions | | | | |
if | Condition that determines whether the wrangle runs as a whole. Recipe variables may be referenced with ${variable}. | string | — | No |
where | Filter rows before applying the wrangle using SQL-like criteria, such as column1 = 123 OR column2 = 'abc'. | string | — | No |
where_params | Values used with where for parameterized criteria. Uses SQLite placeholder syntax such as ? or :name. | array, object | — | No |
Examples
wrangles:
- split.list:
input: Column
output: Column*
wrangles:
- split.list:
input: Column
output:
- Heading A
- Heading B
- Heading C
| Heading A | Heading B | Heading C |
|---|
| A | B | C |
Access
| Requirement | Value |
|---|
| AI-powered | No |
| Requires WrangleWorks account | No |
| Requires subscription | No |
| Requires external API key | No |
Technical details
| Field | Value |
|---|
| Catalog ID | 64 |
| Catalog key | split.list |
| Recipe key | split.list |
| Catalog status | active |
| Lifecycle status | active |
| Recipe Writer eligible | Yes |
| Namespace | split |
| Documentation group | split |
| Aliases | None |
| Runtime symbol | wrangles.recipe_wrangles.split.list |
| Legacy UUID | 3260b9f7-aae2-499f-8004-d211c2cf643e |
Sources
Text
Split a string to multiple columns or a list.
Split text strings on certain characters. The text can be split into either multiple columns or a list.
Parameters
| Name | Description | Accepted Values | Default | Required |
|---|
| I/O | | | | |
input | Name of the column to be split. | string | — | Yes |
output | Name of the output column(s) If a single column is provided, the results will be returned as a list If multiple columns are listed, the results will be separated into the columns. If omitted, will overwrite the input. | string, array, null | null | No |
| Options | | | | |
char | Set the character(s) to split on. Default comma (,) Can also prefix with "regex:" to split on a pattern. | string | "," | No |
element | Select a specific element or range after splitting using slicing syntax. e.g. 0, ":5", "5:", "2:8:2". | string, integer, null | null | No |
inclusive | If true, include the split character in the output. Default False. | boolean | false | No |
skip_empty | Whether to skip empty values. | boolean | false | No |
| Formatting | | | | |
pad | Choose whether to pad to ensure a consistent length. Default true if outputting to columns, false for lists. | boolean, null | null | No |
| Conditions | | | | |
if | Condition that determines whether the wrangle runs as a whole. Recipe variables may be referenced with ${variable}. | string | — | No |
where | Filter rows before applying the wrangle using SQL-like criteria, such as column1 = 123 OR column2 = 'abc'. | string | — | No |
where_params | Values used with where for parameterized criteria. Uses SQLite placeholder syntax such as ? or :name. | array, object | — | No |
Examples
wrangles:
- split.text:
input: Column1
output: Column2
char: ', '
| Column2 |
|---|
| ['Hello', 'Wrangles!'] |
wrangles:
- split.text:
input: Col1
output: Col2
char: 'regex:(?i)x'
wrangles:
- split.text:
input: Column1
output: Column2
char: ', '
element: 0
wrangles:
- split.text:
input: Col
output: Col*
char: ', '
wrangles:
- split.text:
input: Col
output:
- Col 1
- Col 2
- Col 3
char: ', '
| Col 1 | Col 2 | Col 3 |
|---|
| Wrangles | are | Cool! |
Access
| Requirement | Value |
|---|
| AI-powered | No |
| Requires WrangleWorks account | No |
| Requires subscription | No |
| Requires external API key | No |
Technical details
| Field | Value |
|---|
| Catalog ID | 65 |
| Catalog key | split.text |
| Recipe key | split.text |
| Catalog status | active |
| Lifecycle status | active |
| Recipe Writer eligible | Yes |
| Namespace | split |
| Documentation group | split |
| Aliases | None |
| Runtime symbol | wrangles.recipe_wrangles.split.text |
| Legacy UUID | e76e43f7-d129-4bf8-87b4-a304a378b130 |
Sources
Tokenize
Split text into tokens. A variety of methods are available. The default method is to split on spaces.
Tokenize elements in a list or string into individual tokens.
Parameters
| Name | Description | Accepted Values | Default | Required |
|---|
| I/O | | | | |
input | Column(s) to be split into tokens. | string, integer, array | — | Yes |
output | Name of the output column. | string, array, null | null | No |
| Options | | | | |
method | Method to split the list. Options include space, boundary, boundary_ignore_space, custom functions as custom.<function>, or regex patterns as regex:<pattern>. | string; one of:- space
- boundary
- boundary_ignore_space
or string | "space" | No |
| Conditions | | | | |
if | Condition that determines whether the wrangle runs as a whole. Recipe variables may be referenced with ${variable}. | string | — | No |
where | Filter rows before applying the wrangle using SQL-like criteria, such as column1 = 123 OR column2 = 'abc'. | string | — | No |
where_params | Values used with where for parameterized criteria. Uses SQLite placeholder syntax such as ? or :name. | array, object | — | No |
Examples
wrangles:
- split.tokenize:
input: Materials
output: Tokenized List
| Tokenized List |
|---|
| ['Stainless', 'Steel', 'Oak', 'Wood'] |
wrangles:
- split.tokenize:
input: Materials
output: Tokenized List
| Tokenized List |
|---|
| ['Stainless', 'Steel', 'Oak', 'Wood'] |
Access
| Requirement | Value |
|---|
| AI-powered | No |
| Requires WrangleWorks account | No |
| Requires subscription | No |
| Requires external API key | No |
Technical details
| Field | Value |
|---|
| Catalog ID | 66 |
| Catalog key | split.tokenize |
| Recipe key | split.tokenize |
| Catalog status | active |
| Lifecycle status | active |
| Recipe Writer eligible | Yes |
| Namespace | split |
| Documentation group | split |
| Aliases | None |
| Runtime symbol | wrangles.recipe_wrangles.split.tokenize |
| Legacy UUID | 6cc88418-ae0c-43f6-84ee-31e0d5f838c3 |
Sources