Transposing rows and columns: 3 methods
Swapping the rows and columns in a table on the command line would seem to be a fairly easy thing to do [...] Transposing rows and columns is indeed easy if you have the GNU datamash utility on your system [...] I wrote 'trans' as throwaway code for transposing my own tables. It could be extended so that argument 2 specifies the input column separator, and argument 3 a different column separator for the output. There are other ways to swap rows and columns in tables, for example using Perl, but for the time being I'm happy with the script!
|
|
Full Story |
This topic does not have any threads posted yet!
You cannot post until you login.