Given a tbl of blast output format 7 hits can be filtered by evalue, bit_score, query_cov, identity and query_length

filter_blast_hits(
  blast_tbl,
  evalue = NULL,
  bit_score = NULL,
  query_cov = NULL,
  identity = NULL,
  query_length = NULL
)

Arguments

blast_tbl

an object of class tbl from blast output format 7. It must contains below columns.

  1. query_acc_ver

  2. subject_acc_ver

  3. identity

  4. alignment_length

  5. mismatches

  6. gap_opens

  7. q_start

  8. q_end

  9. s_start

  10. s_end

  11. evalue

  12. bit_score

  13. positives

Column names can be assigned using the function get_blast_outformat_7_colnames()

evalue

a numeric value; default NULL. Only hits having evalue <= than given will be retained.

bit_score

a numeric value; default NULL. Only hits having bit_score >= than given will be retained.

query_cov

a numeric value between 0 and 100 ; default NULL. Only hits having query_cov >= than given will be retained. query_cov will be calculated from the column q_start q_end and param query_length

identity

a numeric value between 0 and 100;default NULL. Only hits having identity >= than given will be retained.

query_length

a numeric value indicating length of query sequence.

Value

a tbl of filtered blast hits.

See also

Examples

if (FALSE) { f <- system.file("extdata","blast_output_01.txt" ,package = "phyloR") d <- readr::read_delim(f, delim ="\t" , col_names = F , comment = "#") colnames(d) <- phyloR::get_blast_outformat_7_colnames() filtered <- filter_blast_hits(d , query_cov = 90 , identity = 40, query_length = 249, evalue = 1e-6) }