Skip to main content

Macrel: (Meta)genomic AMP Classification and Retrieval

Pipeline to mine antimicrobial peptides (AMPs) from (meta)genomes.

Build Status Documentation Status License: MIT

Install with Bioconda Install with Bioconda

If you use this software in a publication please cite

Santos-Júnior CD, Pan S, Zhao X, Coelho LP. 2020. Macrel: antimicrobial peptide screening in genomes and metagenomes. PeerJ 8:e10555. DOI: 10.7717/peerj.10555

Run Macrel online: https://big-data-biology.org/software/macrel

License

MIT.

Macrel as a whole is under the MIT license.

Install

The recommended method of installation is through bioconda, using pixi:

pixi global install -c conda-forge -c bioconda macrel
macrel -h

Alternatively, you can use conda (or mamba):

conda create --name env_macrel -c bioconda macrel
conda activate env_macrel
macrel -h

Run without installing

If you have pixi installed, you can run Macrel directly without installing it first:

pixi exec -c conda-forge -c bioconda macrel

To install from source, read the docs

Examples

Macrel uses a subcommand interface. You run macrel COMMAND ... with the COMMAND specifying which components of the pipeline you want to use.

To run these examples, first download the example sequences from github, or by running:

macrel get-examples

The main output file generated by Macrel consists of a table with 6 columns containing the: sequence access code, peptide sequence, classification of peptide accordingly composition and structure, the probability associated with the AMP prediction, hemolytic activity prediction and probability associated to hemolytic activity prediction. All peptides outputted in this table are considered AMPs (p > 0.5), although peptides predicted as AMPs with probabilities closer to 1 are more likely to be active.

To run Macrel on peptides, use the peptides subcommand:

macrel peptides \
    --fasta example_seqs/expep.faa.gz \
    --output out_peptides

In this case, we use example_seqs/expep.faa.gz as the input sequence. This should be an amino-acid FASTA file. The outputs will be written into a folder called out_peptides, and Macrel will 4 threads. An example of output using this mode can be found at tests/peptides/expected.prediction.

To run Macrel on contigs, use the contigs subcommand:

macrel contigs \
    --fasta example_seqs/excontigs.fna.gz \
    --output out_contigs

In this example, we use the example file excontigs.fna.gz which is a FASTA file with nucleotide sequences, writing the output to out_contigs. An example of output using this mode can be found at tests/contigs/expected.prediction. Additionally to the prediction table, this mode also produces two files containing general gene prediction information in the contigs and a fasta file containing the predicted and filtered small genes (≤ 100 amino acids).

To run Macrel on paired-end reads, use the reads subcommand:

macrel reads \
    -1 example_seqs/R1.fq.gz \
    -2 example_seqs/R2.fq.gz \
    --output out_metag \
    --outtag example_metag

The paired-end reads are given as paired files (here, example_seqs/R1.fq.gz and example_seqs/R2.fq.gz). If you only have single-end reads, you can omit the -2 argument. An example of outputs using this mode can be found at tests/reads/expected.prediction and tests/reads/expected.smorfs.faa. Additionally to the prediction table, this mode also produces a contigs fasta file, and the two files containing general gene prediction coordinates and a fasta file containing the predicted and filtered small genes (≤ 100 amino acids).

To run Macrel to get abundance profiles, you only need the short reads file and a reference with peptide sequences. Use the abundance subcommand:

macrel abundance \
    -1 example_seqs/R1.fq.gz \
    --fasta example_seqs/ref.faa.gz \
    --output out_abundance \
    --outtag example_abundance

This mode returns a table of abundances containing two columns, the first with the name of the AMPs and the second with the number of reads mapped back to each peptide using the given reference. An example of this output using the example file can be found at tests/abundances/expected.abundance.txt.

AMPSphere Querying

Macrel also supports querying the AMPSphere database (described in Santos-Júnior et al., 2024). To do so, use the query-ampsphere subcommand:

macrel query-ampsphere \
    --fasta example_seqs/pep8.faa \
    --output out_ampsphere

Note that, by default, this command requires internet access as it uses the AMPSphere API. Alternatively, you can use the --local flag to download a copy of the database and run the queries locally. This only requires the network the first time.

macrel query-ampsphere \
    --local \
    --fasta example_seqs/pep8.faa \
    --output out_ampsphere

By default it performs exact matching, but you can also use MMSeqs2 to perform approximate matching by using the --query-mode=mmseqs (or --query-mode=hmmer for HMMER).

Community

Macrel is actively maintained to fix all issues and assimilate suggestions we get from users (see our commitments to high-quality software).

For general questions about macrel, we ask that you use the AMPSphere Google Group (mailing list).

Technical issues can be reported using Github issues.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

macrel-1.6.1.tar.gz (1.8 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

macrel-1.6.1-py3-none-any.whl (1.8 MB view details)

Uploaded Python 3

File details

Details for the file macrel-1.6.1.tar.gz.

File metadata

  • Download URL: macrel-1.6.1.tar.gz
  • Upload date:
  • Size: 1.8 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.0 CPython/3.11.9

File hashes

Hashes for macrel-1.6.1.tar.gz
Algorithm Hash digest
SHA256 65fcf4bbddd1cc7a9391b331bf300c1d63535d0655282801c49cdd93cc27599b
MD5 73b0f8ebc64710e2a09b52428a7d5678
BLAKE2b-256 8b242e5baabd8c96133a965c83686113c90a8b39042c48f0e667f5eef53ce673

See more details on using hashes here.

File details

Details for the file macrel-1.6.1-py3-none-any.whl.

File metadata

  • Download URL: macrel-1.6.1-py3-none-any.whl
  • Upload date:
  • Size: 1.8 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.0 CPython/3.11.9

File hashes

Hashes for macrel-1.6.1-py3-none-any.whl
Algorithm Hash digest
SHA256 7c0bf4c5d2fc98d02dd797522d92c2345c7c011ca818fe3e017fe2fd3aa22ef1
MD5 3e6a0b90694ea9bc569935a3063d6600
BLAKE2b-256 ca290999fd154be398b6aac17f1efd3d4b4e7de12ab162c7e44b10af9a58962c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page