I often use gridengine's qstat command on our HPC cluster but since I have many jobs running on the cluster the output is too long to fit on my screen and I end up doing a lot of scrolling to see the upper section of the output. My terminal has enough space for two columns so it would be nice if they output could flow into columns and shown side-by-side. Example using simple data file:Obviously this should be general to any screen output so to illustrate here is a simpler example: My file data1.txt contains 100 lines of This is a test.>> cat data1.txtThis is a testThis is a testThis is a testThis is a testThis is a testThis is a testThis is a testThis is a testThis is a testThis is a testThis is a testThis is a testThis is a testThis is a testThis is a testThis is a testThis is a testThis is a testThis is a testThis is a test(etc. until 100th line)>> Desired output:>> cat data1.txt | something | something_else -n 2This is a test  This is a testThis is a test  This is a testThis is a test  This is a testThis is a test  This is a testThis is a test  This is a testThis is a test  This is a testThis is a test  This is a testThis is a test  This is a testThis is a test  This is a testThis is a test  This is a testThis is a test  This is a testThis is a test  This is a testThis is a test  This is a testThis is a test  This is a testThis is a test  This is a testThis is a test  This is a testThis is a test  This is a testThis is a test  This is a testThis is a test  This is a testThis is a test  This is a testThis is a test  This is a testThis is a test  This is a testThis is a test  This is a testThis is a test  This is a testThis is a test  This is a testThis is a test  This is a testThis is a test  This is a test(etc. until 50 rows)Of course, it would be nice to specify any arbitrary number of columns. The only similar question/answer that I found was this one but I'm hoping there is a simpler way to do this in one line using pipes and no script files. 
Stack screen output into columns to make use of screen width and avoid scrolling
linux;pipe;stdout;columns;gridengine
I just found a solution; pipe it to pr. For the example data file:cat data1.txt | pr -2 -l 60And for gridengine's qstat:qstat -f -u * | pr -2 -w 270 -l 130The -2 flag simply specifies 2 columns. You can adjust the width parameter -w to better accomodate the original columnar width and the length parameter -l to adjust the number of pages that the output is split across. For a longer output you probably want a higher -l value. 