Created
August 17, 2015 09:14
-
-
Save explodecomputer/03647e4b309e14f47561 to your computer and use it in GitHub Desktop.
match positions to rsids
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
cd /panfs/panasas01/shared/alspac/studies/latest/alspac/genetic/variants/arrays/gwas/imputed/1000genomes/released/2015-06-25/data/quality | |
rm -f ~/out.txt | |
for i in {1..23} | |
do | |
echo ${i} | |
awk -v chr=$i '{if($1 == chr) print $2}' 1000GP_16-06-14_flipped_SNPs.txt > ~/temp | |
ii=`printf %02d $i` | |
zfgrep -wf ~/temp data_chr${ii}.txt.gz | awk '{ print $2 }' >> ~/out.txt | |
done | |
less ~/out.txt |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment