bug-datamash
[Top][All Lists]
Advanced

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

Re: datamash 1.7 rounding to integer


From: Erik Auerswald
Subject: Re: datamash 1.7 rounding to integer
Date: Wed, 10 Mar 2021 19:46:13 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0

Hi,

On 10.03.21 16:32, Erik Auerswald wrote:
On Wed, Mar 10, 2021 at 09:41:48AM -0500, John Rhee wrote:
[...] I see there's a --format option, but I couldn't find a working example
anywhere.  I've unsuccessfully tried --format="%i" and such.

You could try something like --format='%.0f'.

I have just verified that this works with the current datamash version:

    $ ./datamash --version | head -n1
    datamash (GNU datamash) 1.7.4-d833
    $ seq 10 | ./datamash mean 1
    5.5
    $ seq 10 | ./datamash --format=%.0f mean 1
    6

Thanks,
Erik



reply via email to

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