This is a test version of Biostars. For the public version, visit https://www.biostars.org.
How To Get Blast+ (Stand Alone Blast) Output To Contain Only The First Hit For Each Record In The Database?

Greetings! I'm using BLAST+ v. 2.2.26, and would like to customize the output to include only the FIRST hit for each separate record in the data base. The region I am using as the query is a domain with many copies in a gene and I don't need all the matches, just the best one for each gene in the database.

blast

2 answers

duplicate of

Check out section 4.2.12 in the BLAST+ Command line options book. In particular, take a look at the -best_hit_overhang and -best_hit_score_edge options. Also, there are a number of different approaches you can take if you already have the blast report. Check out Best Blast Hit Without Pain answer here on BioStars or this answer from SeqAnswers for working with tab-delimited reports, and there are also Standalone Blast Options for getting the best hit only from almost any blast report format.

Log in to answer this question.