Question: Converting genotypes to allele frequencies
gravatar for 110300553
6 months ago by
1103005530 wrote:

I have a table of genotpyes (AA, GG, CT etc.) per sample and their corresponding rsids. I don't have any other corresponding files, just this .txt table, is there a way for me to batch convert these to allele counts in R(0,1,2)? I've found a lot of people doing this individually by SNP but I have 100K + rsids and want to examine them all.

snp R genome • 192 views
ADD COMMENTlink modified 6 months ago by JC8.2k • written 6 months ago by 1103005530

Can you provide example file, something like: myData[ 1:10, 1:10 ] ?

ADD REPLYlink written 6 months ago by zx87547.9k
gravatar for JC
6 months ago by
JC8.2k wrote:

You probably need to create a script that does the conversion, you can use the NCBI API ( to query each rs and define which allele is the reference (0) and any other allel (1,2, ...)

ADD COMMENTlink written 6 months ago by JC8.2k
Please log in to add an answer.


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