Question: How to combine txt file to convert in Plink format
0
gravatar for bha
10 days ago by
bha0
bha0 wrote:

My 26 data files (.txt) (imputed genotypes for each chromosome) look like:

CHR SNP1 SNP2 SNP3
1   3   1   2   3 
1   3   0   2   1
1   0   0   1   0
1   0   3   3   1
1   1   1   0   2

CHR SNP1 SNP2 SNP3
2   1   1   2   2 
2   0   3   1   1
2   0   0   1   0
2   0   3   3   2
2   3   2   0   1

How I can convert them in plink format (.map and .ped)?

snp R • 168 views
ADD COMMENTlink modified 10 days ago by Kevin Blighe6.7k • written 10 days ago by bha0

please post expected output.

ADD REPLYlink modified 10 days ago • written 10 days ago by cpad01123.0k

ID SNP1 SNP2 SNP3

17 3 1 2 3

25 3 0 2 1

29 0 0 1 0

99 0 3 3 1

81 1 1 0 2

similarly other 25 files for chromosome 2,3,.....26.

ADD REPLYlink modified 10 days ago • written 10 days ago by bha0

Hi bha, I have edited your post to make it more legible. When you're posting code or output from a command or file, make use of the 'Code Sample' button (the one with 101 010). Highlight the text and then click the button.

ADD REPLYlink written 10 days ago by Kevin Blighe6.7k

Hello bha!

It appears that your post has been cross-posted to another site: https://stackoverflow.com/questions/47225587/

This is typically not recommended as it runs the risk of annoying people in both communities.

ADD REPLYlink written 10 days ago by Pierre Lindenbaum101k
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 1123 users visited in the last hour