[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

GNU Datamash 1.5 released

From: Assaf Gordon
Subject: GNU Datamash 1.5 released
Date: Tue, 17 Sep 2019 16:25:41 -0600
User-agent: Mutt/1.11.4 (2019-03-13)

This is to announce datamash-1.5, a new stable release.

Datamash is a command-line program which performs basic numeric,textual
and statistical operations on input textual data files.

GNU Datamash home page:

Please report any problem you may experience to the
address@hidden mailing list.

Happy Hacking!
- Assaf Gordon


Here are the compressed sources and a GPG detached signature[*]:

Use a mirror for higher download bandwidth:

[*] Use a .sig file to verify that the corresponding file (without the
.sig suffix) is intact.  First, be sure to download both the .sig file
and the corresponding tarball.  Then, run a command like this:

gpg --verify datamash-1.5.tar.gz.sig

If that command fails because you don't have the required public key,
then run this command to import it:

gpg --keyserver --recv-keys 0A11B61D3657B901

and rerun the 'gpg --verify' command.


The checksums of the archive are:

$ sha1sum datamash-1.5.tar.gz
ba35ed8130005a8a2bb0869f0e67b67378b7d1ce  datamash-1.5.tar.gz

$ sha256sum datamash-1.5.tar.gz

$ sha512sum datamash-1.5.tar.gz

$ b2sum datamash-1.5.tar.gz



** New Features

  Datamash now accepts backslash-escaped characters in field names.
  This allows working with named fields containing dash/mins,colons,commas
  or field names starting with digits (Note the interplay between
  backslash and shell quoting). The following are equivalent,
  and sum an input field named 'FOO-BAR':
      datamash -H sum FOO\\-BAR < input.txt
      datamash -H sum 'FOO\-BAR' < input.txt
      datamash -H sum "FOO\\-BAR" < input.txt

  New operations: dirname, basename
  These behave just like dirname(1) and basename(1):
     $ echo /home/foo/bar.txt | datamash dirname 1 basename 1
     /home/foo    bar.txt

  New operations: extname, barename
  'extname' extract the extension of the file name.
  'barename' (not to be confused with 'basename') extract the basename
  without the extension.
     $ echo /home/foo/bar.tar.gz | datamash barename 1 extame 1
     bar         tar.gz

  New operation: getnum
  This operation extracts a number from a string.
  'getnum' accepts an optional single letter option:
     getnum:n - natural numbers (positive integers, including zero)
     getnum:i - integers
     getnum:d - decimal point numbers
     getnum:p - positive decimal point numbers (this is the default)
     getnum:h - hex numbers
     getnum:o - octal numbers
     $ echo foo-42.0-bar | datamash getnum 1
     $ echo foo-42.0-bar | datamash getnum:n 1
     $ echo foo-42.0-bar | datamash getnum:i 1
     $ echo foo-42.0-bar | datamash getnum:d 1

  New operation: cut
  Similar to cut(1), it copies the input field to the output as-is.
  The advantage over cut(1) is that combined with datamash's other features,
  input fields can be specified by name instead of column number, and
  output fields can be re-ordered and duplicated.
    $ printf "a b c\n1 X 6\n" | datamash -W -H cut c,a,c
    cut(c)  cut(a)  cut(c)
    6       1       6

** Bug fixes

  Datamash now correctly calculates mode/antimode for negative values.
  In version 1.4 and earlier, the following produced incorrect results:
    $ echo -1 | datamash-1.4 mode 1

reply via email to

[Prev in Thread] Current Thread [Next in Thread]