[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: A new 'transpose' coreutil
From: |
Pádraig Brady |
Subject: |
Re: A new 'transpose' coreutil |
Date: |
Thu, 17 Dec 2015 16:38:27 +0000 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.3.0 |
On 17/12/15 16:25, Assaf Gordon wrote:
> Hello,
>
> On 12/17/2015 06:00 AM, Pádraig Brady wrote:
>> On 17/12/15 05:06, Ryan wrote:
>>> Hi everybody,
>>>
>>> I looked through the rejected feature requests and did not find this.
>>> I and others I know have often wished for an efficient 'transpose'
>>
>> Interesting.
>
> GNU Datamash ( http://www.gnu.org/software/datamash/ ) can transpose files
> from the command line:
>
> $ cat 1.txt
> Genes NOX1 DcP HH
> Sample A1 A2 B3
> Counts 514 542 490
>
> $ datamash transpose < 1.txt
> Genes Sample Counts
> NOX1 A1 514
> DcP A2 542
> HH B3 490
>
> In addition to performing other various statistical and text-related
> operations (in the coming version: also cross-tabulation, a.k.a pivot-tables).
Oh nice,
This project is a better match for any such changes.
BTW I did search for "GNU transpose utility" in various
combinations and didn't notice this.
I suggest to mention it at
http://unix.stackexchange.com/questions/88142/command-to-transpose-swap-rows-and-columns-of-a-text-file
http://stackoverflow.com/questions/1729824/transpose-a-file-in-bash
http://unix.stackexchange.com/questions/79642/transposing-rows-and-columns
Also maybe apply some SEO to the function names at:
http://www.gnu.org/software/datamash/manual/datamash.html
thanks!
Pádraig