randarium
Data

Categorical Data Generator

Create reproducible categorical test data from your own labels. Assign weights to categories when some values should occur more often, or generate a unique sample.

Also known as: random category · weighted categories · categorical sampler

seeded

Higher weights make a category more likely. Set every weight to 1 for uniform sampling.

Output

No output yet — set your options and hit .
About this tool, tips & examples

What it does

The Categorical Data Generator samples reproducible values from labels you define — statuses, plans, segments, severities — with an optional weight per label. Give active weight 8 and churned weight 2 and the output runs roughly 80/20. It’s the fastest way to fill a column with realistic, controlled categorical test data.

Common use cases

  • Mock API and database fixtures — a status or tier column with a realistic skew instead of uniform noise.
  • Survey and event simulations — responses distributed the way real ones would be.
  • Documentation examples — repeatable categorical samples for tutorials and screenshots.
  • Edge-case control — crank a rare label’s weight to zero or make it dominant, and watch how downstream code copes.

Settings

  • Categories and weights — your labels with positive weights. Weights are relative, not percentages: 8 vs 2 just means four times as likely.
  • How many — the number of values to draw.
  • Unique categories — each label appears at most once (sampling without replacement) — useful for drawing a subset rather than a distribution.
  • Output — plain values or structured rows, exportable as text, CSV, or JSON.
  • Seed — the same seed and settings always regenerate identical output.

Privacy note

Values are generated locally in your browser and never uploaded. The output is synthetic test data drawn from your labels — it represents no real people or events.

FAQ

Can I make all categories equally likely? Yes — give every label the same weight (e.g. 1 each).

Do weights guarantee exact proportions? No. Weights set probabilities; finite samples vary around them. A 90/10 weighting over 20 draws might come out 17/3. Larger samples track the weights more closely.

How is this different from the Weighted Picker? Same sampling idea, different job: the Weighted Picker picks winners from a list interactively; this tool bulk-generates a data column and exports it.