This is a test version of Biostars. For the public version, visit https://www.biostars.org.
merge cases and controls with plink

Hello. I have a dataset of cases and a dataset of controls which have been genotyped on different platforms. So, for a particular SNP, it can happen that I have the same allele coding both in cases and in controls; or it can happen that I have in controls the reverse of cases (e.g.: A C in cases and T G or G T in controls). I want to merge the files of cases and controls, but the allele coding should be consistent: which procedure can I follow? Please, let me know. Thanks!

gwas plink

which have been genotyped differently.

Please be as informative as possible when asking questions.

1 answer

One possible workflow is described at http://www.cog-genomics.org/plink/1.9/data#merge3 .

Thanks, it is very helpful. After the merge fails because alleles are not consistent in cases and controls, I flip alleles in the .missnp file which is generated, thus obtaining new binary files. With these files and the cases I do the merging; the alleles in the .bim files of cases and controls are almost always the same, except for very few cases in which allele1 and allele2 columns are inverted (e.g.: A G in cases and G A in controls). However I can now manage to merge files without problems, so I guess that is not a problem. I am though wondering whether it is fair to have these alleles inverted in cases and controls. Is it a matter of different frequencies?

If this answer was helpful you should upvote it, if the answer resolved your question you should mark it as accepted. Upvote|Bookmark|Accept

Log in to answer this question.