I have a .txt file (new_file.txt
) with a column of values (200). I need to print another column beside it, with values 0,1/200,2/200.....1. How should I do this? I am new to this, so any suggestions will be great!
I know that seq 0 0.005 1 >new_file.txt
will print it into the file, but it overwrites the values already present. I want to add these numbers as another column beside the values already present in the file.
The input is like:
2.41
2.56
etc. in a column. I need it to look like
2.41 0
2.56 0.005
etc. in a column. I need to have a tab in between.
paste
orpr
command... suggest to show small sample (say 5 lines) for input and how the output should look after column addition.. should it be added with space/tab/etc in between or without any separation? – Sundeep Jul 2 '17 at 2:55