Question: Using Blast Command Line to output unaligned FASTA
1
gravatar for sharabesh97
2.3 years ago by
sharabesh9710
sharabesh9710 wrote:

I am attempting to search for a set of homologs using BLAST command line. I currently am using the command blastp -db swissprot -query [FASTA_FILE] -evalue 0.005 -out homologs.fasta.

However, I am ideally looking for BLAST to output all the FASTA sequences of the hits to my query sequence in unaligned form. Is there a modification I can make to support this?

blast homologs fasta • 1.7k views
ADD COMMENTlink modified 2.3 years ago by 5heikki8.4k • written 2.3 years ago by sharabesh9710
2
gravatar for 5heikki
2.3 years ago by
5heikki8.4k
Finland
5heikki8.4k wrote:

You can do e.g. this:

blastp -db swissprot -query [FASTA_FILE] -evalue 0.005 -outfmt '6 sseqid sseq' \
    | awk 'BEGIN{FS="\t"; OFS="\n"}{gsub(/-/, "", $2); print ">"$1,$2}' \
    > homologs.fasta
ADD COMMENTlink modified 2.3 years ago • written 2.3 years ago by 5heikki8.4k

Thank you that worked very well!

ADD REPLYlink written 2.3 years ago by sharabesh9710
0
gravatar for fred.s.kremer
2.3 years ago by
Brazil
fred.s.kremer70 wrote:

Please, take a look at this post in SEQanswers:

http://seqanswers.com/forums/showthread.php?t=8805

They basically recommend the construction of a list of IDS for those sequences in the database that matched and than used the blastdbcmd program to extract them from the BLAST database.

ADD COMMENTlink modified 2.3 years ago • written 2.3 years ago by fred.s.kremer70
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 942 users visited in the last hour