If you don't have GNU R and want a table that adjusts to the input given, you could try something like:
As always, if you're using a Solaris/SunOS system, use /usr/xpg4/bin/awk or nawk instead of awk.
With the input file given in the 1st message in this thread, it produces the output:
And, with the input given in message #3 in this thread, it produces:
Last edited by Don Cragun; 03-13-2013 at 01:17 AM..
Reason: Add output produced with alternative input
This User Gave Thanks to Don Cragun For This Post:
Hi,
Can any one please help me in converting a tab delimited file in .csv file.
Records in my file are similar to mentioned below:
DET 001 0201 AC032508970 01478E1X8
DET 002 0202 AC032508971 01478E1X8
Could any one please suggest me what approach would be more suitable for this or if... (5 Replies)
I have a text file that made using text editor in Ubuntu. However the text file is not being recognized as space or tab delimited, the formatting seems to be messed up. How can I convert the text file into tab delimited format? (3 Replies)
I have a file which looks like this:
73450 articles and news developmental psychology 2006-03-30 16:22:40 1 http://www.usnews.com
73450 articles and news developmental psychology 2006-03-30 16:22:40 2 http://www.apa.org
73450 articles and news developmental psychology 2006-03-30... (1 Reply)
Hi,
Can anyone please tell me about how we can delete an entire column from a tab delimited file?
Mu input_file.txt looks like this:
And I want the output as:
I used the below code
nawk -v d="1" 'BEGIN{FS=OFS="\t"}{$d=""}{print}' input_file.txtBut in the output, the first column is... (5 Replies)
Hello,
I have a text file with space and tab (mixed) delimited file and need to convert into CSV.
# cat test.txt
/dev/rmt/tsmmt32 HP Ultrium 6-SCSI J3LZ 50:03:08:c0:02:72:c0:b5 F00272C0B5 0/0/6/1/1.145.17.255.0.0.0 /dev/rmt/c102t0d0BEST
/dev/rmt/tsmmt37 ... (6 Replies)
Hi, I have a rquirement in unix as below .
I have a text file with me seperated by | symbol and i need to generate a excel file through unix commands/script so that each value will go to each column.
ex:
Input Text file:
1|A|apple
2|B|bottle
excel file to be generated as output as... (9 Replies)
Hi
i have a problem in my job
i try to convert an excel file (xls extention) to text file (tab delimited), but no result with this comand
cat xxx.xls > xxx.txt
Do you have eny idea?
PS: sorry for my english
Thanks!! (4 Replies)