Dataset Row Sampler and Splitter

Select rows reproducibly or split a CSV into disjoint parts, preserving source order within each exported table.

Inputs stay on your device No sign-up Free to use
How this works

The tool runs in this browser. Your file or text is not uploaded to UseFreeTools. Check this tool's limits for anything it may save on your device.

Privacy details

Sample or split rows controls

Showing an example. Edit to see your own.

Paste a CSV with a heading row. Up to 100,000 data rows, 500 columns and 2,000,000 cells. Every value is kept as text, so a leading zero survives.

The random and split methods are reproducible: the same seed and row count always give the same assignment.

Used by the random sample. It cannot exceed the number of data rows.

Used by the every-nth method. A value of 3 with a start row of 1 keeps rows 1, 4, 7 and so on.

The first row the every-nth method can keep. It cannot be larger than the nth value.

Used by the train and test split. The row count is rounded and clamped so both parts hold at least one row.

A whole number from 0 to 4294967295 for the mulberry32 generator.

Set the delimiter yourself when a quoted cell confuses detection.

A cell whose first visible character is = + - or @ receives an apostrophe in both downloads. Turn it off to keep the raw value.

Processed in your browser. Your inputs stay on this device.

How to use Dataset Row Sampler and Splitter

  1. Paste a rectangular CSV table with unique headers.
  2. Choose random sampling, systematic sampling or a train/test split.
  3. Set the count or percentage and the seed or interval required by that mode.
  4. Review output counts and download both parts.

Example: Dataset Row Sampler and Splitter

Keep alternate rows in source order.

You add
CSV: id,name 1,A 2,B 3,C 4,D. Method: Every nth; interval: 2; start row: 1.
You get
The selected CSV contains IDs 1 and 3. The remainder contains IDs 2 and 4, with both exports retaining source order.

Options

Sampling method
Random sample and train/test split use the supplied reproducible seed. Every-nth selection uses an interval and 1-based start row while keeping source order.
Seed and split percentage
The same seed and row count reproduce the same assignment. Changing row order changes which records those positions represent. The split is rounded and bounded so both parts keep at least one row.

Supported inputs and limits

Up to 20 MiB CSV, 100,000 records, 500 columns and 2,000,000 cells. Random selection uses the documented seeded algorithm without replacement; it is not a secure random source. Percentages use the displayed rounding rule. Outputs contain every source record exactly once between the two parts. Sampling does not prove statistical representativeness.

Where your input is processed

This tool processes your input in this browser. Your text and files are not uploaded to UseFreeTools. Check this tool's limits for anything it may save on your device.

A sample is not a representativeness guarantee

A selected subset can miss rare cases or preserve bias already present in the source. This tool chooses rows; it does not stratify on labels or prove that a train/test split avoids related-record leakage. Review the assignment against the job that needs the sample.

Preserve the remainder and the selection recipe

Both selected and remaining records are available. Keep the original row order, method, interval or seed when you need to reproduce an extraction. Formula protection can change exported text, so retain its setting with the recipe.

Questions about Dataset Row Sampler and Splitter

Will the same seed produce the same rows?

Yes, with the same input order, mode and settings. Editing or reordering the source can change which rows that seed selects.

Can a record appear in both exports?

No. The sample/remainder or train/test parts are disjoint and together contain all source records.

Does random sampling remove selection bias automatically?

No. It only applies the selected algorithm to the rows you supplied. Review the source population and the purpose of the sample.

Project manager: Tony Hines · Content updated 4 October 2026 · Report a problem