Hi,
I have a space delimited text file with multiple columns 102 columns. I want to break it up into 100 files labelled 1.txt through 100.txt (n.txt). Each text file will contain the first two columns and in addition the nth column (that corresponds to n.txt). The third file will contain the first three columns and the fourth file will contain columns 1,2 and 4 and so on.
I have a two files, file A and B, which have 5 columns, and each 5 columns are made up of random numbers, that means, numbers are all different.
Hi again,
I have monthly one-column files of roughly around 10 years. Is there a more efficient way to concatenate these files column-wise other than using paste command? For instance:
Code:
file1.txt
12
13
15
12
file2.txt
14
15
18
19
file3.txt
20
21
13
12
expected output (one file containing all the concatenated columns)
12 14 20
13 15 21
15 18 13
12 19 12
Thank you in advance.
Hello All,
I have a .CSV file where I expect all numeric data in all the columns other than column headers.
But sometimes I get the files (result of statistics computation by other persons) like below( sample data)
Code:
SNO,Data1,Data2,Data3
1,2,3,4
2,3,4,SOME STRING
3,4,Inf,5
4,5,4,4
I want to remove the columns where ever character strings( I cannot provide the complete list as it is
input_file (columns are tab delimited, only column 4 contains spaces)
A B C D;<>X;<>Y 0
C D E F;<>Z;<>X 1
Output_file
A B C D;<>X;<>Y;<>apple=0
C D E F;<>Z;<>X;<>apple=1
I would like to merge the last column of input_file with the second last column and separate the value of last column with ";" and a tag "apple=" in second last co
Given columned text in a file that is delimited by a certain character, how do you truncate the width of either a specific column(s) or all columns?
The use case is that I am reading some log files that have space delimited columns. Some of the columns in the log are very long urls that make the file difficult to read.
Source 1
Code:
column1 column2 column 3 column4
1,ganesh,1,000,1
222,ram,2,000,5
222,ram,50,000,5
33,raju,5,000,7
33,raju,5,000,7
33,raju,5,000,8
33,raju,5,000,4
33,raju,5,000,1
In my .csv file, third column is having price value with comma (20,300), it has to be considered 1,000 as single column.my output should have only 4 columns not 5 columns .
Hello everyone,
I searched the forum looking for answers to this but I could not pinpoint exactly what I need as I keep having trouble.
I have many files each having two columns and hundreds of rows.
first column is a string (can have many words) and the second column is a number.The files are tab separated.
dear friends,
attached are two sorted files. I want to merge them using key column: Column #2 in first file and column #1 in the second file. I want to show all columns in the merged output file.