[Top][All Lists]

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

Re: datamash performance question

From: Dima Kogan
Subject: Re: datamash performance question
Date: Fri, 25 Jun 2021 13:38:47 -0700
User-agent: mu4e 1.4.15; emacs 28.0.50

I'd be curious to see ways to make datamash work faster here, but if all
you're doing is computing sums, you can use awk instead of datamash:

  mawk '{s[$2] += $1;} END { for (k in s) {print k, s[k]; } }'

Then you can probably also get rid of your sort and sed calls.

reply via email to

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