This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Finding upstream or downstream sequences on BLAST on linux

Hi all,

I got a WG assembly sequence of an organism which is not on the online BLAST, so I'm using Linux. After creating a DB of it, I start searching for different genes and it works just fine - now I want to see the sequences upstream and downstream to my hit - but I didn't find out how to do it.

Please help! Thanks :-)

genome sequencing alignment gene

You could do as @gb suggests by parsing the -outfmt 6 output of blastn for sstart (column 9) and send (column 10), convert to BED file but add however many bases upstream and downstream you want, and intersect the BED file to the annotations in GFF or GTF format with Bedtools.

Hopefully you created your custom database with --parse_seqids option.

If you did then you can use blastdbcmd utility includes in blast+ to retrieve any sequences using the following option.

-range <String>
   Range of sequence to extract in 1-based offsets (Format: start-stop, for
   start to end of sequence use start - )
 -strand <String, `minus', `plus'>
   Strand of nucleotide sequence to extract
   Default = `plus'

Combine it with sstart and send as suggested by others.

0 answers

No answers yet.

Log in to answer this question.