Can someone provide me insight into how to extract a specific region of a FastQ file to run BLAST on?
1
0
Entering edit mode
3.4 years ago
screadore ▴ 20

Can someone provide me insight into how to extract a specific region of a FastQ file to run BLAST on?

genome sequence Assembly alignment • 979 views
ADD COMMENT
1
Entering edit mode
3.4 years ago

FASTQ files are not aligned, so extracting a specific region is not possible. Align first, then you can pull reads that aligned to specific regions.

ADD COMMENT
0
Entering edit mode

Which file type should I be looking for? BAM? Then once I have a BAM or whichever file type how could I pull the specific region.

ADD REPLY
2
Entering edit mode

You can use samtools view to extract a specific region/chromosome etc from a sorted and indexed bam file:

samtools view -o <out.bam> <in.bam> chr1:100-1000 # saves all alignments against chromosome 1 between 100-1000 bp positions.

You can print or save the alignments to SAM format with samtools view <out.bam> > <out.sam>. You can visualize the alignments on IGV browser too.

ADD REPLY
0
Entering edit mode

Thank you so much this was extremely helpful!

ADD REPLY

Login before adding your answer.

Traffic: 1635 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