Table Partitioner

The input table is split row-wise into two partitions, for instance into a train and test data set. The two partitions are available at the two output ports.

Options

First partition type
Defines how the size of the first partition is specified: as a percentage of total rows (relative) or as an absolute number of rows.
Relative size
Specifies the percentage of rows from the input table to be included in the first partition. Must be between 0 and 100 (inclusive).
Number of rows
Specifies the absolute number of rows to include in the first partition. If the input table contains fewer rows than specified, all rows are placed in the first table, and the second table will be empty.
Sampling strategy
Determines how rows are selected for the first partition. Strategies include random, linear, stratified, and first rows (sequential).
  • Random: Randomly selects rows from the input table. You can optionally specify a random seed for reproducible results.
  • Stratified: Preserves the distribution of values in the selected group column. You can optionally specify a random seed for reproducible stratified sampling.
  • Linear: Selects rows evenly spaced across the input table, always including the first and last row. This method is useful for downsampling sorted columns while preserving boundary values.
  • First rows: Allows you to select the top-most rows of the input table.
Group column
Specifies the column whose value distribution should be preserved in stratified sampling. Ensures both output tables reflect the same distribution of values.
Fixed random seed
Optional seed value for random or stratified sampling. Using a seed ensures the same rows are selected each time the node is executed. Without a seed, a different random selection will occur each time.
If input table is empty
Defines how the node should behave when the input table has no rows. Options include generating empty outputs or failing the execution.

Input Ports

Icon
Table to partition.

Output Ports

Icon
Rows from the input table that have been selected as per the node configuration.
Icon
Remaining rows from the input table.

Popular Predecessors

Views

This node has no views

Workflows

Links

Developers

You want to see the source code for this node? Click the following button and we’ll use our super-powers to find it for you.