miller README

The project's README from github.com/johnkerl/miller. As one markdown file: README.md.

What is Miller?

Miller is like awk, sed, cut, join, and sort for data formats such as CSV, TSV, JSON, JSON Lines, and positionally-indexed.

What can Miller do for me?

With Miller, you get to use named fields without needing to count positional indices, using familiar formats such as CSV, TSV, JSON, JSON Lines, and positionally-indexed. Then, on the fly, you can add new fields which are functions of existing fields, drop fields, sort, aggregate statistically, pretty-print, and more.

cover-art

In the above image you can see how Miller embraces the common themes of key-value-pair data in a variety of data formats.

Installing

There's a good chance you can get Miller pre-built for your system: Ubuntu Ubuntu 16.04 LTS Fedora Debian Gentoo Pro-Linux Arch Linux NetBSD FreeBSD Anaconda Snap Homebrew/MacOSX MacPorts/MacOSX Chocolatey WinGet

OS Installation command
Linux yum install miller
apt-get install miller
snap install miller
Mac brew install miller
port install miller
Windows choco install miller
winget install Miller.Miller
scoop install main/miller

See also README-versions.md for a full list of package versions. Note that long-term-support (LtS) releases will likely be on older versions.

See also building from source.

Features

Getting started

deepwiki

More documentation links

Community

GitHub stars Homebrew downloads Conda downloads

All Contributors

Build status

Multi-platform build status CodeQL status Codespell status 🧪 Snap Builds

Building from source

For developers

License

License: BSD2

What people are saying about Miller

Today I discovered Miller—it's like jq but for CSV: https://t.co/pn5Ni241KM

Also, "Miller complements data-analysis tools such as R, pandas, etc.: you can use Miller to clean and prepare your data." @GreatBlueC @nfmcclure

— Adrien Trouillaud (@adrienjt) September 24, 2020

Underappreciated swiss-army command-line chainsaw.

"Miller is like awk, sed, cut, join, and sort for [...] CSV, TSV, and [...] JSON." https://t.co/TrQqSUK3KK

— Dirk Eddelbuettel (@eddelbuettel) February 28, 2017

Miller looks like a great command line tool for working with CSV data. Sed, awk, cut, join all rolled into one: http://t.co/9BBb6VCZ6Y

— Mike Loukides (@mikeloukides) August 16, 2015

Miller is like sed, awk, cut, join, and sort for name-indexed data such as CSV: http://t.co/1zPbfg6B2W - handy tool!

— Ilya Grigorik (@igrigorik) August 22, 2015

Btw, I think Miller is the best CLI tool to deal with CSV. I used to use this when I need to preprocess too big CSVs to load into R (now we have vroom, so such cases might be rare, though...)https://t.co/kUjrSSGJoT

— Hiroaki Yutani (@yutannihilat_en) April 21, 2020

Miller: a *format-aware* data munging tool By @__jo_ker__ to overcome limitations with *line-aware* workshorses like awk, sed et al https://t.co/LCyPkhYvt9

The project website is a fantastic example of good software documentation!!

— Donny Daniel (@dnnydnl) September 9, 2018

Holy holly data swiss army knife batman! How did no one suggest Miller https://t.co/JGQpmRAZLv for solving database cleaning / ETL issues to me before

Congrats to @__jo_ker__ for amazingly intuitive tool for critical data management tasks!#DataScienceandLaw #ComputationalLaw

— James Miller (@japanlawprof) June 12, 2018

🤯@__jo_ker__'s Miller easily reads, transforms, + writes all sorts of tabular data. It's standalone, fast, and built for streaming data (operating on one line at a time, so you can work on files larger than memory).

And the docs are dream. I've been reading them all morning! https://t.co/Be2pGPZK6t

— Benjamin Wolfe (he/him) (@BenjaminWolfe) September 9, 2021

Contributors ✨

Thanks to all the fine people who help make Miller better (emoji key):


Andrea Borruso

🤔 🎨

Shaun Jackman

🤔

Fred Trotter

🤔 🎨

komosa

🤔

jungle-boogie

🤔

Thomas Klausner

🚇

Stephen Kitt

📦

Leah Neukirchen

🤔

Luigi Baldoni

📦

Hiroaki Yutani

🤔

Daniel M. Drucker

🤔

Nikos Alexandris

🤔

kundeng

📦

Victor Sergienko

📦

Adrian Ho

🎨

zachp

📦</

miller (johnkerl/miller)

tabular-data
Searching Database…

10K ·GitHub
What is this?Miller is a command-line toolkit like awk, sed, cut, join, and sort, but built for name-indexed data such as CSV, TSV, JSON, and JSON Lines: you address fields by name instead of counting column positions.
So is it a library I import, or a command I run?A standalone command-line executable, not a library. Where classic Unix tools see numbered array slots, Miller sees each record as an insertion-ordered key-value map, and its processing is format-aware.
What's the install command on my machine?Prebuilt packages: brew or port on macOS; yum, apt, or snap on Linux; choco, winget, or scoop on Windows (e.g. winget install Miller.Miller). Building from source with make or go install also works.
Do I need any runtimes or libraries installed first?None. Miller is written in portable, modern Go with zero runtime dependencies — a single binary you can scp to a faraway machine and expect to work.
Will the copy in my package manager be the latest version?Not necessarily: the README notes long-term-support (LtS) releases are likely on older versions, so check README-versions.md or build from source if you need the newest one.
Why pick Miller over pandas or R for data work?They're complements, not rivals: you can clean and prepare data with Miller on the command line, then load the result into R or pandas for deeper statistics and graphics. Its streaming single-pass algorithms also let you shrink very large files before those tools ever see them.
Can it convert files between formats?Yes — its I/O formats include CSV, TSV, JSON, JSON Lines, positionally-indexed, and tabular pretty-printing, and Miller converts between them. Conversion is format-aware: for example, sorting a CSV keeps the header line first.
What is the command actually called?mlr — that's the executable you run (mlr.exe on Windows). Building from source produces ./mlr, and go install puts it in GOPATH/bin.
Can I use it like a quick database over my files?For one-off tasks, yes: the README touts setup-free querying of data sitting in disk files when you're in a hurry, and Miller can also slice, dice, and reformat data on its way into or out of a SQL database.
What are similar projects?visidata, xsv, q, yq, fx, gron, SolidityScanLegend, coreutils
Creator
johnkerl
Size
212.2 MB
Stars
10K
Age
11y
Commits · 90 Days