mirror of
https://github.com/johnkerl/miller.git
synced 2026-01-23 02:14:13 +00:00
Update webdocs for latest mlr compile
This commit is contained in:
parent
0c1adb1396
commit
6a41f73328
12 changed files with 50 additions and 31 deletions
1
Makefile
1
Makefile
|
|
@ -48,6 +48,7 @@ dev:
|
|||
make build
|
||||
make check
|
||||
make -C man build
|
||||
make -C docs/src forcebuild
|
||||
make -C docs
|
||||
@echo DONE
|
||||
|
||||
|
|
|
|||
|
|
@ -9,3 +9,10 @@ genmds: $(FILES)
|
|||
%.md: %.md.in
|
||||
@./genmds $<
|
||||
|
||||
# Do this to force-build if the *.md.in inputs are unchanged but something else
|
||||
# is, e.g. mlr source-code changes as affecting the output of autogen code
|
||||
# snippets.
|
||||
forcebuild:
|
||||
@./genmds
|
||||
|
||||
.PHONY: forcebuild
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ You will need to first install Go version 1.15 or higher: please see [https://go
|
|||
|
||||
## Miller license
|
||||
|
||||
Two-clause BSD license [https://github.com/johnkerl/miller/blob/main/LICENSE.txt](https://github.com/johnkerl/miller/blob/main/LICENSE.txt).
|
||||
Two-clause BSD license [https://github.com/johnkerl/miller/blob/master/LICENSE.txt](https://github.com/johnkerl/miller/blob/master/LICENSE.txt).
|
||||
|
||||
## From release tarball
|
||||
|
||||
|
|
@ -95,7 +95,7 @@ In this example I am using version 6.1.0 to 6.2.0; of course that will change fo
|
|||
* Notify:
|
||||
|
||||
* Submit `brew` pull request; notify any other distros which don't appear to have autoupdated since the previous release (notes below)
|
||||
* Similarly for `macports`: [https://github.com/macports/macports-ports/blob/main/textproc/miller/Portfile](https://github.com/macports/macports-ports/blob/main/textproc/miller/Portfile)
|
||||
* Similarly for `macports`: [https://github.com/macports/macports-ports/blob/master/textproc/miller/Portfile](https://github.com/macports/macports-ports/blob/master/textproc/miller/Portfile)
|
||||
* Social-media updates.
|
||||
|
||||
<pre class="pre-non-highlight-non-pair">
|
||||
|
|
|
|||
|
|
@ -243,7 +243,7 @@ purple triangle 0 257 0.435535 0.859129 0.812290 5.753095
|
|||
red square 0 322 0.201551 0.953110 0.771991 5.612050
|
||||
</pre>
|
||||
|
||||
Look at uncategorized stats (using [creach](https://github.com/johnkerl/scripts/blob/main/fundam/creach) for spacing).
|
||||
Look at uncategorized stats (using [creach](https://github.com/johnkerl/scripts/blob/master/fundam/creach) for spacing).
|
||||
|
||||
Here it looks reasonable that `u` is unit-uniform; something's up with `v` but we can't yet see what:
|
||||
|
||||
|
|
|
|||
|
|
@ -546,7 +546,8 @@ While you can do format conversion using `mlr --icsv --ojson cat myfile.csv`, th
|
|||
<b>mlr help format-conversion</b>
|
||||
</pre>
|
||||
<pre class="pre-non-highlight-in-pair">
|
||||
No help found for "format-conversion" -- please try 'mlr help topics'.
|
||||
No help found for "format-conversion". Please try 'mlr help find format-conversion' for approximate match.
|
||||
See also 'mlr help topics'.
|
||||
</pre>
|
||||
|
||||
<!---
|
||||
|
|
@ -575,7 +576,8 @@ You can include comments within your data files, and either have them ignored, o
|
|||
<b>mlr help comments-in-data</b>
|
||||
</pre>
|
||||
<pre class="pre-non-highlight-in-pair">
|
||||
No help found for "comments-in-data" -- please try 'mlr help topics'.
|
||||
No help found for "comments-in-data". Please try 'mlr help find comments-in-data' for approximate match.
|
||||
See also 'mlr help topics'.
|
||||
</pre>
|
||||
|
||||
Examples:
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@ MILLER(1) MILLER(1)
|
|||
|
||||
|
||||
NAME
|
||||
miller - like awk, sed, cut, join, and sort for name-indexed data such
|
||||
Miller -- like awk, sed, cut, join, and sort for name-indexed data such
|
||||
as CSV and tabular JSON.
|
||||
|
||||
SYNOPSIS
|
||||
|
|
@ -50,7 +50,7 @@ DESCRIPTION
|
|||
insertion-ordered hash map. This encompasses a variety of data
|
||||
formats, including but not limited to the familiar CSV, TSV, and JSON.
|
||||
(Miller can handle positionally-indexed data as a special case.) This
|
||||
manpage documents Miller v6.0.0-dev.
|
||||
manpage documents mlr 6.0.0-dev.
|
||||
|
||||
EXAMPLES
|
||||
mlr --icsv --opprint cat example.csv
|
||||
|
|
@ -172,11 +172,10 @@ HELP OPTIONS
|
|||
mlr -F = mlr help usage-functions
|
||||
mlr -k = mlr help list-keywords
|
||||
mlr -K = mlr help usage-keywords
|
||||
Lastly, 'mlr help ...' will search for your text '...' using the sources of
|
||||
Lastly, 'mlr help ...' will search for your exact text '...' using the sources of
|
||||
'mlr help flag', 'mlr help verb', 'mlr help function', and 'mlr help keyword'.
|
||||
For things appearing in more than one place, e.g. 'sec2gmt' which is the name of a
|
||||
verb as well as a function, use `mlr help verb sec2gmt' or `mlr help function sec2gmt'
|
||||
to disambiguate.
|
||||
Use 'mlr help find ...' for approximate (substring) matches, e.g. 'mlr help find map'
|
||||
for all things with "map" in their names.
|
||||
|
||||
VERB LIST
|
||||
altkv bar bootstrap cat check clean-whitespace count-distinct count
|
||||
|
|
@ -935,6 +934,7 @@ VERBS
|
|||
Fills empty-string fields with specified fill-value.
|
||||
Options:
|
||||
-v {string} Fill-value: defaults to "N/A"
|
||||
-S Don't infer type -- so '-v 0' would fill string 0 not int 0.
|
||||
|
||||
filter
|
||||
Usage: mlr filter [options] {DSL expression}
|
||||
|
|
@ -1677,7 +1677,6 @@ VERBS
|
|||
-a {sum,count,...} Names of accumulators: one or more of:
|
||||
median This is the same as p50
|
||||
p10 p25.2 p50 p98 p100 etc.
|
||||
TODO: flags for interpolated percentiles
|
||||
count Count instances of fields
|
||||
mode Find most-frequently-occurring values for fields; first-found wins tie
|
||||
antimode Find least-frequently-occurring values for fields; first-found wins tie
|
||||
|
|
@ -1711,15 +1710,10 @@ VERBS
|
|||
case please avoid pprint-format output since end of input
|
||||
stream will never be seen).
|
||||
-h|--help Show this message.
|
||||
[TODO: more]
|
||||
Example: mlr stats1 -a min,p10,p50,p90,max -f value -g size,shape
|
||||
mlr stats1
|
||||
Example: mlr stats1 -a count,mode -f size
|
||||
mlr stats1
|
||||
Example: mlr stats1 -a count,mode -f size -g shape
|
||||
mlr stats1
|
||||
Example: mlr stats1 -a count,mode --fr '^[a-h].*$' -gr '^k.*$'
|
||||
mlr stats1
|
||||
This computes count and mode statistics on all field names beginning
|
||||
with a through h, grouped by all field names starting with k.
|
||||
|
||||
|
|
@ -2602,7 +2596,7 @@ FUNCTIONS FOR FILTER/PUT
|
|||
|
||||
KEYWORDS FOR PUT AND FILTER
|
||||
all
|
||||
all: used in "emit", "emitp", and "unset" as a synonym for @*
|
||||
all: used in "emit1", "emit", "emitp", and "unset" as a synonym for @*
|
||||
|
||||
begin
|
||||
begin: defines a block of statements to be executed before input records
|
||||
|
|
@ -2663,6 +2657,16 @@ KEYWORDS FOR PUT AND FILTER
|
|||
else: terminates an if/elif/elif chain. The body statements must be wrapped
|
||||
in curly braces.
|
||||
|
||||
emit1
|
||||
emit1: inserts an out-of-stream variable into the output record stream. Unlike
|
||||
the other map variants, side-by-sides, indexing, and redirection are not supported,
|
||||
but you can emit any map-valued expression.
|
||||
|
||||
Example: mlr --from f.dat put 'emit1 $*'
|
||||
Example: mlr --from f.dat put 'emit1 mapsum({"id": NR}, $*)'
|
||||
|
||||
Please see https://miller.readthedocs.io://johnkerl.org/miller/doc for more information.
|
||||
|
||||
emit
|
||||
emit: inserts an out-of-stream variable into the output record stream. Hashmap
|
||||
indices present in the data but not slotted by emit arguments are not output.
|
||||
|
|
@ -2975,5 +2979,5 @@ SEE ALSO
|
|||
|
||||
|
||||
|
||||
2021-11-08 MILLER(1)
|
||||
2021-11-19 MILLER(1)
|
||||
</pre>
|
||||
|
|
|
|||
|
|
@ -2958,4 +2958,4 @@ SEE ALSO
|
|||
|
||||
|
||||
|
||||
2021-11-18 MILLER(1)
|
||||
2021-11-19 MILLER(1)
|
||||
|
|
|
|||
|
|
@ -159,7 +159,7 @@ coinmate
|
|||
|
||||
## Randomly generating jabberwocky words
|
||||
|
||||
These are simple *n*-grams as [described here](http://johnkerl.org/randspell/randspell-slides-ts.pdf). Some common functions are [located here](https://github.com/johnkerl/miller/blob/main/docs/ngrams/ngfuncs.mlr.txt). Then here are scripts for [1-grams](https://github.com/johnkerl/miller/blob/main/docs/ngrams/ng1.mlr.txt), [2-grams](https://github.com/johnkerl/miller/blob/main/docs/ngrams/ng2.mlr.txt), [3-grams](https://github.com/johnkerl/miller/blob/main/docs/ngrams/ng3.mlr.txt), [4-grams](https://github.com/johnkerl/miller/blob/main/docs/ngrams/ng4.mlr.txt), and [5-grams](https://github.com/johnkerl/miller/blob/main/docs/ngrams/ng5.mlr.txt).
|
||||
These are simple *n*-grams as [described here](http://johnkerl.org/randspell/randspell-slides-ts.pdf). Some common functions are [located here](https://github.com/johnkerl/miller/blob/master/docs/ngrams/ngfuncs.mlr.txt). Then here are scripts for [1-grams](https://github.com/johnkerl/miller/blob/master/docs/ngrams/ng1.mlr.txt), [2-grams](https://github.com/johnkerl/miller/blob/master/docs/ngrams/ng2.mlr.txt), [3-grams](https://github.com/johnkerl/miller/blob/master/docs/ngrams/ng3.mlr.txt), [4-grams](https://github.com/johnkerl/miller/blob/master/docs/ngrams/ng4.mlr.txt), and [5-grams](https://github.com/johnkerl/miller/blob/master/docs/ngrams/ng5.mlr.txt).
|
||||
|
||||
The idea is that words from the input file are consumed, then taken apart and pasted back together in ways which imitate the letter-to-letter transitions found in the word list -- giving us automatically generated words in the same vein as *bromance* and *spork*:
|
||||
|
||||
|
|
|
|||
|
|
@ -859,6 +859,7 @@ dump
|
|||
edump
|
||||
elif
|
||||
else
|
||||
emit1
|
||||
emit
|
||||
emitf
|
||||
emitp
|
||||
|
|
@ -908,7 +909,7 @@ ORS
|
|||
<b>mlr help usage-keywords # you can also use mlr -K</b>
|
||||
</pre>
|
||||
<pre class="pre-non-highlight-in-pair">
|
||||
all: used in "emit", "emitp", and "unset" as a synonym for @*
|
||||
all: used in "emit1", "emit", "emitp", and "unset" as a synonym for @*
|
||||
|
||||
begin: defines a block of statements to be executed before input records
|
||||
are ingested. The body statements must be wrapped in curly braces.
|
||||
|
|
@ -959,6 +960,15 @@ in curly braces.
|
|||
else: terminates an if/elif/elif chain. The body statements must be wrapped
|
||||
in curly braces.
|
||||
|
||||
emit1: inserts an out-of-stream variable into the output record stream. Unlike
|
||||
the other map variants, side-by-sides, indexing, and redirection are not supported,
|
||||
but you can emit any map-valued expression.
|
||||
|
||||
Example: mlr --from f.dat put 'emit1 $*'
|
||||
Example: mlr --from f.dat put 'emit1 mapsum({"id": NR}, $*)'
|
||||
|
||||
Please see https://miller.readthedocs.io://johnkerl.org/miller/doc for more information.
|
||||
|
||||
emit: inserts an out-of-stream variable into the output record stream. Hashmap
|
||||
indices present in the data but not slotted by emit arguments are not output.
|
||||
|
||||
|
|
|
|||
|
|
@ -876,6 +876,7 @@ Usage: mlr fill-empty [options]
|
|||
Fills empty-string fields with specified fill-value.
|
||||
Options:
|
||||
-v {string} Fill-value: defaults to "N/A"
|
||||
-S Don't infer type -- so '-v 0' would fill string 0 not int 0.
|
||||
</pre>
|
||||
|
||||
<pre class="pre-highlight-in-pair">
|
||||
|
|
@ -2981,7 +2982,6 @@ Options:
|
|||
-a {sum,count,...} Names of accumulators: one or more of:
|
||||
median This is the same as p50
|
||||
p10 p25.2 p50 p98 p100 etc.
|
||||
TODO: flags for interpolated percentiles
|
||||
count Count instances of fields
|
||||
mode Find most-frequently-occurring values for fields; first-found wins tie
|
||||
antimode Find least-frequently-occurring values for fields; first-found wins tie
|
||||
|
|
@ -3015,15 +3015,10 @@ Options:
|
|||
case please avoid pprint-format output since end of input
|
||||
stream will never be seen).
|
||||
-h|--help Show this message.
|
||||
[TODO: more]
|
||||
Example: mlr stats1 -a min,p10,p50,p90,max -f value -g size,shape
|
||||
mlr stats1
|
||||
Example: mlr stats1 -a count,mode -f size
|
||||
mlr stats1
|
||||
Example: mlr stats1 -a count,mode -f size -g shape
|
||||
mlr stats1
|
||||
Example: mlr stats1 -a count,mode --fr '^[a-h].*$' -gr '^k.*$'
|
||||
mlr stats1
|
||||
This computes count and mode statistics on all field names beginning
|
||||
with a through h, grouped by all field names starting with k.
|
||||
|
||||
|
|
|
|||
|
|
@ -2958,4 +2958,4 @@ SEE ALSO
|
|||
|
||||
|
||||
|
||||
2021-11-18 MILLER(1)
|
||||
2021-11-19 MILLER(1)
|
||||
|
|
|
|||
|
|
@ -2,12 +2,12 @@
|
|||
.\" Title: mlr
|
||||
.\" Author: [see the "AUTHOR" section]
|
||||
.\" Generator: ./mkman.rb
|
||||
.\" Date: 2021-11-18
|
||||
.\" Date: 2021-11-19
|
||||
.\" Manual: \ \&
|
||||
.\" Source: \ \&
|
||||
.\" Language: English
|
||||
.\"
|
||||
.TH "MILLER" "1" "2021-11-18" "\ \&" "\ \&"
|
||||
.TH "MILLER" "1" "2021-11-19" "\ \&" "\ \&"
|
||||
.\" -----------------------------------------------------------------
|
||||
.\" * Portability definitions
|
||||
.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue