Search Results

Search: Posts Made By: Unilearn
2,187
Posted By Unilearn
Hi Jim, Thanks for a quick reply. ...
Hi Jim,

Thanks for a quick reply.

Indeed I want to remove duplicates across files. So, that is alright. However, is there a way to extract only the first "n" number of rows from each file?...
2,187
Posted By Unilearn
Extract unique combination of rows from text files
Hi Gurus,

I have 100 tab-delimited text files each with 21 columns. I want to extract only 2nd and 5th column from each text file. However, the values in both 2bd and 5th column contain duplicate...
3,822
Posted By Unilearn
Hello Hagama, Thanks a lot for the code...it...
Hello Hagama,

Thanks a lot for the code...it works but I get duplicate names from all three columns from text files. I would prefer to have duplicate names only from the first columns of of text...
3,822
Posted By Unilearn
finding overlapping names in different txt files
Dear Gurus,

I have 57 tab-delimited different text files, each one containing entries in 3 columns. The first column in each file contains names of objects. Some names are present in more than one...
22,704
Posted By Unilearn
thanks a lot for the script Jim. It works if I...
thanks a lot for the script Jim. It works if I have three columns to calculate. How can do it if the file has more than 100 columns? Is there a way to mention the range like column 1 to column 150...
22,704
Posted By Unilearn
Calculate average for rows in a text file
Dear Gurus,

I have tab-delimited text files with matrix containing values. The first column is a identifier and other columns have the corresponding values. I would like to calculate the average...
2,059
Posted By Unilearn
thanks a ton!
thanks a ton!
2,059
Posted By Unilearn
thank you ludwig. But I have one question on your...
thank you ludwig. But I have one question on your code. Where can I indicate the input file and output file in the code?
2,059
Posted By Unilearn
shift values in one column as header for values in another column
Hi Gurus,

I have a tab separated text file with two columns. I would like to make the first column values as headings for the second column values.

Ex.
>value1 subjects
>value2 priorities...
2,090
Posted By Unilearn
Extract columns from multiple files with a file name as heading
Hi All,

I have 7 files, each containing 9 columns separated by space. I want to extract the 9th columns from every file and save in a new file. The columns must be pasted next to each other. And...
3,487
Posted By Unilearn
Wow that is great! It is working...
Wow that is great!

It is working fine..thanks a lot..would appreciate if you could tell how did you do that. of course when you have time.

Cheers
3,487
Posted By Unilearn
oh there should be space! Please see the...
oh there should be space!

Please see the attached text for ex.

Cheers
3,487
Posted By Unilearn
Here you go, File.txt MarkerName ...
Here you go,

File.txt

MarkerName Allele1 Allele2 Freq1 FreqSE Weight Zscore P-value Direct
1kg_2_25451489 c g 0.3220 0.0329 233.00 3.732 0.0001903+++-...
3,487
Posted By Unilearn
Thanks a lot bartus11. That is working fine....
Thanks a lot bartus11.

That is working fine. However, I still have this problem...

The 8th coloumn in my text file contains the values which are less than 1. Hence the text file puts them in...
3,487
Posted By Unilearn
replace "," with "." only in specific columns of a file?
Hi all,

I have this text file containing 9 columns separated by space. The 8th columns contains the numbers.

C1 C2 C3 C4 C5 C6 C7 C8 C9
er rt yt gh iu nk il 0.07 xs
yt lr ty bg iu zk nh...
4,211
Posted By Unilearn
sort by keeping the headings intact?
Hi all,

I have a file with 3 columns separated by space. Each column has a heading. I want to sort according to the values in the 2nd column (ascending order).

Ex.
Name rank direction
goory...
1,458
Posted By Unilearn
That was the trick! Thanks a lot Peasant! That...
That was the trick! Thanks a lot Peasant! That works great.
1,458
Posted By Unilearn
Thanks Yazu for the reply. I am using...
Thanks Yazu for the reply.

I am using cygwin on windows. I tried
paste -d' ' file1 file2

but still I am getting the same output.

Any other options??

Thanks,
1,458
Posted By Unilearn
Hi All, When I try paste, I am having this...
Hi All,

When I try paste, I am having this problem.

Ex.
file1.txt contains 9 coloumns
C1 C2 C3 C4 C5 C6 C7 C8 C9
23 34 45 45 56 67 89 45 35
...

file2.txt contains 3 columns
a1 a2 a3 ...
1,458
Posted By Unilearn
Merging two text files with variable coloumns
Hi All,

I have two text files containing space delimited columns. The first file contains 9 columns and the second one contain 3 columns. I want to copy the 3 coloumns from the 2nd file and paste...
1,823
Posted By Unilearn
Printing columns with header
Hi Gurus,

I want to extract certain columns from file 2 and combine with file 1.
I am using the following script to extract the columns.
$ awk 'FNR>1{print $2, $9, FILENAME}' *.lim > out1
...
3,599
Posted By Unilearn
Thanks a million. Appreciate your explanation!...
Thanks a million. Appreciate your explanation! That was very useful.
3,599
Posted By Unilearn
Wow that works great getmmg! Thanks a lot! Now...
Wow that works great getmmg!
Thanks a lot! Now only if I know how does it work!
3,599
Posted By Unilearn
Hi getmmg, Thanks for the code. It works...
Hi getmmg,

Thanks for the code. It works fine. But after merging the 7th and 8th columns, it leaves the 8th, 10th, 12th etc. columns empty. For ex.

output:
1 mike 0 0 2 1 AA__GG__CT__AG
1...
3,599
Posted By Unilearn
combine the values from the first two columns within a file
Hello everybody,

I have a text file containing 10,000 rows and 5000 columns. The values are separated by a tab.
Ex.

file_ex.ped
1 mike 0 0 2 1 A A G G C T A G
1 jack 0 0 2 2 T A G T C A A C...
Showing results 1 to 25 of 39

 
All times are GMT -4. The time now is 04:24 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy