Skip to main content

a python package for graphing emapper results

Project description

egger

a python package to plot results from eggnog-mapper and calculate correlations

Description

egger can plot COG functional annotations from eggnog-mapper annotation files.

The repository for eggnog-mapper can be found, here.

It has two modes:

  • compare: compares the correlation of COG categories across several genomes.
  • window: plots sliding window plots of COG category distribution across a genome.

See below for usage examples.

Installation

You can install egger with pip.

Either use the PyPI installation: pip install egger.

Or, clone this repository and install manually.

egger only requires Python dependencies, which should be installed automatically.

Usage and Example Output

As described above, egger has two modes:

compare

compare output

egger compare will calculate the correlation of COG category annotations across genomes and build a dendrogram-heatmap. It will write this as .svg file along with the raw data in .tsv formats. It can perform Spearman's rank (-s) or Pearson's (-p) correlation. It can also produce barcharts (-b). Use: egger compare -h for more information.

Here is an example using this repository's example_data/outputs/compare_outputs as the working directory:

$ egger compare -b barchart -s spearmans -p pearsons ../../inputs/annotations/*

compare output

These heatmaps can help identify relationships between genomes or other sequences.

Compare example output

window

window usage

egger window will take eggnog-mapper annotations and plot them using a sliding window. Please note, as eggnog-mapper annotations do not contain location data, the original genome used for the analysis is also required. You will also need to define outputs with -swo or -swp. You can also modify the window and step size using. Use: egger window -h for more information.

Here is an example using this repository's example_data/outputs/window_outputs as the working directory:

egger window -a ../../inputs/annotations/Lactococcus_lactis.annotations -g ../../inputs/genomes/Lactococcus_lactis.gb -swo output_ -swp plot_

window output

This will produce two files:

  1. -swo writes a .tsv file with the raw data used for plotting the sliding window.
  2. -swp writes a .html file for an interactive plot of the sliding window data.

This analysis is particularly useful for finding regions of the genome that are dedicated to a specific function. In the example, Lactococcus lactis has three notable islands for the COG categories J, M and P (among others). example window output

Citation

Coming soon...

Patch Notes

  • v1.0.0
    • Initial version
  • v1.0.1
    • Updated parser text
    • Upated input parsing to accept wildcards

Project details


Download files

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

Source Distribution

egger-1.0.1.tar.gz (24.4 kB view details)

Uploaded Source

Built Distribution

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

egger-1.0.1-py3-none-any.whl (27.3 kB view details)

Uploaded Python 3

File details

Details for the file egger-1.0.1.tar.gz.

File metadata

  • Download URL: egger-1.0.1.tar.gz
  • Upload date:
  • Size: 24.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.10.12

File hashes

Hashes for egger-1.0.1.tar.gz
Algorithm Hash digest
SHA256 dc01ab9b89b7dea418e581bbaf1f93dffb31e0d64df33b792d9a37d95091fa1c
MD5 689e1efc1ceca24e7c244588eeeba6cb
BLAKE2b-256 aa1f92f99aa28590bd31d0cefac9f3a26690ffbd9f140be95c289065f085d24f

See more details on using hashes here.

File details

Details for the file egger-1.0.1-py3-none-any.whl.

File metadata

  • Download URL: egger-1.0.1-py3-none-any.whl
  • Upload date:
  • Size: 27.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.10.12

File hashes

Hashes for egger-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 b596199b71486a18f48bb76efd90d9417f0ffcd0d68e59bcd236d6fb273d57d7
MD5 98d1f27d29c34a22831a8a81da27ce8b
BLAKE2b-256 bd8bb63c9430a6dc6d45291100330f54df9036fc772711a63d6b1f47b7a48f5e

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 Pingdom Monitoring Sentry Error logging StatusPage Status page