I would like to extract sequence around snp from the human genome like below. Is there any tools to do this?
Extract Flanking Region Of A Snp
Get Flanking Sequence Given A List Of Positions
@Jonessara770 Did you find a way to extract the SNP flanking sequences.
Use 'samtools faidx', if you know the position of snp. You will also require the relevant reference build:
samtools faidx ref.fasta chr1:2500026-2500063
adjust the range as required.
Create a bed file with range containing your snp position: chr pos-offset pos+offet
Exemple with 3 snps : (chr3:150050 ,chr4:150050,chr5:150050) and 10 nucleotid size margin :
chr 3 150040 1500060
chr 4 150040 1500060
chr 5 150040 1500060
Then use bedtools to extract your sequences
bedtools getfasta -fi hg19.fa -bed snp.bed -fo out.fa
You should get a list of all sequences founded.
once extract the SNP flanking sequences (bedtools getfasta), how to indicates SNP position in brackets [ ] with REF/ALT bases
Login before adding your answer.
Use of this site constitutes acceptance of our User Agreement and Privacy