An open API service indexing awesome lists of open source software.

https://github.com/sandyjmacdonald/blast_parser

Parses .xml formatted blast results files and returns query and hit IDs.
https://github.com/sandyjmacdonald/blast_parser

Last synced: 12 days ago
JSON representation

Parses .xml formatted blast results files and returns query and hit IDs.

Awesome Lists containing this project

README

          

> [!IMPORTANT]
> **This repository has moved to Codeberg.**
>
> Active development now happens at **[https://codeberg.org/sandyjmacdonald/blast_parser](https://codeberg.org/sandyjmacdonald/blast_parser)**.
>
> This GitHub copy is archived and read-only. Please file issues, open pull requests, and follow the project on Codeberg.

---

blast_parser.py
============

Takes a .xml formatted BLAST results file as input and prints the query ID, hit ID, percentage identity, query length, alignment length and e value for sequences passing the thresholds passed via the command line arguments.

### Dependencies

Requires [Biopython](http://biopython.org) for parsing of BLAST .xml files.

### Usage

```bash
python blast_parser.py -i -e 1e-20 -p 97 -a 100 > parsed_results.txt
```

> ##### Arguments

> `-i` The BLAST results file (in .xml format) that you want to parse.

> `-e` e value threshold. Can be a float or integer value.

> `-p` Percentage identity cutoff. Can be a float or integer value between 0 and 100.

> `-a` Minimum alignment length cutoff. Can be a float or integer value.

> `-h` Displays help.