is it possible to know individual genotype(alleles) by SNP in plink?
1
1
Entering edit mode
4.2 years ago
nayeona.hi ▴ 60

I made 3 binary files from MAP and PED files.
I'd like to know how to get individual genotypes per specific SNP.

When I open the .bim file, I just see the SNP and allele information but individual information (i.e. sample Id)

How to map the information?

I'd like to get information like this, and could open in Python or R.

Do I need some other tools for that? please let me know. For example,

SNP      SAMPLE     GENOTYPE 
rs53576    1111         AA
rs53576    1112         GA
rs53576    1113         GG
rs53576    1114         GA

Thank you in advance.

plink SNP individual • 1.9k views
ADD COMMENT
2
Entering edit mode
4.2 years ago
Sam ★ 4.8k
plink --bfile <Bed file prefix> --extract <File contain SNP ID> --recode --out <name of output>

This should generate the desired output

ADD COMMENT
0
Entering edit mode

I think they need --recode transpose.

ADD REPLY
1
Entering edit mode

--recode will generate the ped file, which split the genotype into two columns. With --recode transpose you will get one variant per column, where the fifth and sixth fields are allele calls for the first sample in the .tfam file ('0' = no call); the 7th and 8th are allele calls for the second individual; and so on.

There are a large number of recode formats, maybe they can consult the manual page here https://www.cog-genomics.org/plink/1.9/data#recode

ADD REPLY
0
Entering edit mode

--list and --snp options also worked. Thank you

ADD REPLY

Login before adding your answer.

Traffic: 1715 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6