Skip to content
pederbePublic

About

Fast, GNU datamash-compatible command-line statistics for Linux and macOS, written in Rust

Topics

Resources

Code of conduct

Contributing

Security policy

Stars

1 star

Watchers

0 watching

Forks

Latest commit

 

History

401 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Fastmash

Fast command-line statistics for delimited text.
A Rust implementation of the GNU datamash command language.

Pull request CI Latest release MIT license or Apache 2.0 license

Documentation · Install · Benchmarks · Migrating from datamash


Fastmash summarizes, groups and reshapes tab-separated text and quoted CSV from the command line. It accepts the command language of GNU datamash, so most existing scripts can switch by changing one word.

$ printf 'site\treading\nwest\t2\neast\t4\nwest\t6\n' | fastmash -H -s -g site sum reading mean reading
GroupBy(site)	sum(reading)	mean(reading)
east	4	4
west	8	4

Why Fastmash

  • Speed. Up to four times faster than GNU datamash 1.9 in published Linux benchmarks.
  • Familiar commands. Over 70 operations and modes, with grouping, headers, field selectors, percentiles, crosstab and transpose.
  • CSV and table tools. Read and write quoted CSV, name result columns, calculate weighted means, select top records, compare datasets and check table health.
  • Repeatable results. Software arithmetic gives identical numerical results across supported machines for the same input, settings and Fastmash version.

Install

Fastmash runs on Linux (glibc), Windows through WSL2 and macOS 15 and later.

Install prebuilt programs with your package manager. On Debian or Ubuntu, add the signed apt repository. On Fedora, RHEL and similar systems:

sudo curl -fsSLo /etc/yum.repos.d/fastmash.repo https://packages.fastmash.io/fastmash.repo
sudo dnf install fastmash

With Homebrew on macOS or Linux:

brew install pederbe/tap/fastmash

On any supported system, the quick installer downloads the latest release:

curl -fsSL https://fastmash.io/install.sh | sh

The installation guide also covers single packages, release archives, cargo-binstall and compiling with Cargo.

Quick start

# Sum CSV revenue by region and name the result column
fastmash --csv -H -s -g region --result-name=1:total sum revenue < sales.csv

# Weighted mean and the highest five complete records
fastmash -H wmean price:units < sales.tsv
fastmash --csv -H top:5 revenue < sales.csv

# Check table health and compare summaries of two exports
fastmash --header-in health type revenue number nonmissing id validate < sales.tsv
fastmash --csv -H -g region compare before.csv after.csv sum revenue

Use --csv for quoted CSV and -H to select fields by header name. The user guide covers all operations and options.

Compatibility

Fastmash implements the GNU datamash 1.9 command language. See the migration guide to switch existing scripts and the documented differences for compatibility details.

Documentation

Contributing

Found a bug or have a workload to share? Open an issue or read the contributing guide. Report vulnerabilities through the security policy.


Created by Peder Bergan

About

Fast, GNU datamash-compatible command-line statistics for Linux and macOS, written in Rust

Topics

Resources

Code of conduct

Contributing

Security policy

Stars

1 star

Watchers

0 watching

Forks

Releases

Sponsor this project

Packages

Used by

Contributors

Languages