msplotter


Namemsplotter JSON
Version 0.1.37 PyPI version JSON
download
home_page
SummaryMake a graphical representation of a blastn alignment
upload_time2023-08-06 03:03:15
maintainer
docs_urlNone
author
requires_python>=3.11
licenseBSD 3-Clause License
keywords blast alignment graphical representation dna sequence easyfig
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            <p align="center">
   <img src="./src/msp/images/logo.png" alt="MSPlotter" width="350">
</p>

# Make a graphical representation of a blastn alignment

Multiple Sequence Plotter (MSPlotter) uses GenBank files (.gb) to align the
sequences and plot the genes. MSPlotter uses the information from the `CDS`
features section to plot the genes. To customize the colors for plotting genes,
you can add a `Color` tag in the `CDS` features with color in hexadecimal.
For example, add the tag `/Color="#00ff00"` to show a gene in green. To avoid
direct manual manipulation of the GenBank file, you can edit the file with
`Geneious` or another software and export the file with the new annotations.

MSPlotter is an easy-to-use option for people with little coding knowledge or
problems running the classic app `easyfig`. The program offers a graphical user
interface (GUI) and a command line interface (CLI).

If the user knows Python, MSPlotter uses `matplotlib`. Therefore, to customize
your figure, the user can modify the parameters in the `MakeFigure` class of
the `msplotter` module or make any necessary change in any part of the code.

I am developing MSPlotter in my free time, therefore, if you find a bug, it may
take me some time to fix it, but I will try to do my best to fix the problems
as soon as possible. Also, if you have any suggestions, let me know, and I will
try to implement them.

## Requirements

- [Python](https://www.python.org/) 3.11 or later
- [biopython](https://biopython.org/) 1.81 or later
- [customtkinter](https://customtkinter.tomschimansky.com/) 5.1 or later
- [matplotlib](https://matplotlib.org/) 3.7 or later
- [blastn](https://www.ncbi.nlm.nih.gov/books/NBK569861/) must be installed
  locally and in the path

MSPlotter has been tested in macOS and Windows.

## Installation

First, create a virtual environment with `conda` or `venv`. Then, install
msplotter using pip as follows:

```bash
pip install msplotter
```

## Usage and options

To run the GUI type:

```bash
msplotter --gui
```

Output GUI:

<p align="center">
   <img src="./src/msp/images/MSPlotter_gui.png" alt="MSPlotter" width="350">
</p>

To view all the options run:

```bash
msplotter --help
```

Partial output CLI:

```console
usage: msplotter [-h] [-v] [-i INPUT [INPUT ...]] [-o OUTPUT] [-n NAME] [-f FORMAT] [-d DPI]
                 [--alignments_position ALIGNMENTS_POSITION] [--identity_color IDENTITY_COLOR]
                 [--annotate_sequences [ANNOTATE_SEQUENCES]] [--annotate_genes [ANNOTATE_GENES]] [-g]

Make a graphical representation of a blastn alignment.

Help:
  -h, --help            Show this help message and exit.
  -v, --version         Show program's version number and exit

Required:
  -i INPUT [INPUT ...], --input INPUT [INPUT ...]
                        Path to input files. Provided files must be GenBank files.

Optional:
  -o OUTPUT, --output OUTPUT
                        Path to output folder.
                        Default: current working directory.
  -n NAME, --name NAME  Name of figure.
                        Default: `figure`.
  -f FORMAT, --format FORMAT
                        Format of figure. Options: pdf, png, and svg.
                        For a complete list of valid options visit:
                        https://matplotlib.org/stable/api/_as_gen/matplotlib.pyplot.savefig.html
                        Default: `png`.
  -d DPI, --dpi DPI     Resolution in dots per inch.
                        Default: 300 (high resolution for print).
  --alignments_position ALIGNMENTS_POSITION

```

## Usage examples CLI

To make a figure with default parameters:

```bash
msplotter -i path/file_1.gb path/file_2.gb path/file_3.gb
```

To save a figure in pdf format:

```bash
msplotter -i path/file_1.gb path/file_2.gb path/file_3.gb -f pdf
```

## Notes

I started this project to make a figure paper with three sequences with lengths
between 8 to 23 kb. However, the matplotlib parameters can be adjusted for
larger, smaller, or more sequences.

## Credits

Inspired by easyfig: Sullivan et al (2011) Bioinformatics 27(7):1009-1010

## License

BSD 3-Clause License

            

Raw data

            {
    "_id": null,
    "home_page": "",
    "name": "msplotter",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.11",
    "maintainer_email": "",
    "keywords": "blast,alignment,graphical representation,DNA sequence,easyfig",
    "author": "",
    "author_email": "Ivan Mu\u00f1oz-Gutierrez <ivan.munoz.gutierrez@gmail.com>",
    "download_url": "https://files.pythonhosted.org/packages/46/32/605aae053e857bdfd45ab26818fb87a033ae73ac1b167d6732368e28509c/msplotter-0.1.37.tar.gz",
    "platform": null,
    "description": "<p align=\"center\">\n   <img src=\"./src/msp/images/logo.png\" alt=\"MSPlotter\" width=\"350\">\n</p>\n\n# Make a graphical representation of a blastn alignment\n\nMultiple Sequence Plotter (MSPlotter) uses GenBank files (.gb) to align the\nsequences and plot the genes. MSPlotter uses the information from the `CDS`\nfeatures section to plot the genes. To customize the colors for plotting genes,\nyou can add a `Color` tag in the `CDS` features with color in hexadecimal.\nFor example, add the tag `/Color=\"#00ff00\"` to show a gene in green. To avoid\ndirect manual manipulation of the GenBank file, you can edit the file with\n`Geneious` or another software and export the file with the new annotations.\n\nMSPlotter is an easy-to-use option for people with little coding knowledge or\nproblems running the classic app `easyfig`. The program offers a graphical user\ninterface (GUI) and a command line interface (CLI).\n\nIf the user knows Python, MSPlotter uses `matplotlib`. Therefore, to customize\nyour figure, the user can modify the parameters in the `MakeFigure` class of\nthe `msplotter` module or make any necessary change in any part of the code.\n\nI am developing MSPlotter in my free time, therefore, if you find a bug, it may\ntake me some time to fix it, but I will try to do my best to fix the problems\nas soon as possible. Also, if you have any suggestions, let me know, and I will\ntry to implement them.\n\n## Requirements\n\n- [Python](https://www.python.org/) 3.11 or later\n- [biopython](https://biopython.org/) 1.81 or later\n- [customtkinter](https://customtkinter.tomschimansky.com/) 5.1 or later\n- [matplotlib](https://matplotlib.org/) 3.7 or later\n- [blastn](https://www.ncbi.nlm.nih.gov/books/NBK569861/) must be installed\n  locally and in the path\n\nMSPlotter has been tested in macOS and Windows.\n\n## Installation\n\nFirst, create a virtual environment with `conda` or `venv`. Then, install\nmsplotter using pip as follows:\n\n```bash\npip install msplotter\n```\n\n## Usage and options\n\nTo run the GUI type:\n\n```bash\nmsplotter --gui\n```\n\nOutput GUI:\n\n<p align=\"center\">\n   <img src=\"./src/msp/images/MSPlotter_gui.png\" alt=\"MSPlotter\" width=\"350\">\n</p>\n\nTo view all the options run:\n\n```bash\nmsplotter --help\n```\n\nPartial output CLI:\n\n```console\nusage: msplotter [-h] [-v] [-i INPUT [INPUT ...]] [-o OUTPUT] [-n NAME] [-f FORMAT] [-d DPI]\n                 [--alignments_position ALIGNMENTS_POSITION] [--identity_color IDENTITY_COLOR]\n                 [--annotate_sequences [ANNOTATE_SEQUENCES]] [--annotate_genes [ANNOTATE_GENES]] [-g]\n\nMake a graphical representation of a blastn alignment.\n\nHelp:\n  -h, --help            Show this help message and exit.\n  -v, --version         Show program's version number and exit\n\nRequired:\n  -i INPUT [INPUT ...], --input INPUT [INPUT ...]\n                        Path to input files. Provided files must be GenBank files.\n\nOptional:\n  -o OUTPUT, --output OUTPUT\n                        Path to output folder.\n                        Default: current working directory.\n  -n NAME, --name NAME  Name of figure.\n                        Default: `figure`.\n  -f FORMAT, --format FORMAT\n                        Format of figure. Options: pdf, png, and svg.\n                        For a complete list of valid options visit:\n                        https://matplotlib.org/stable/api/_as_gen/matplotlib.pyplot.savefig.html\n                        Default: `png`.\n  -d DPI, --dpi DPI     Resolution in dots per inch.\n                        Default: 300 (high resolution for print).\n  --alignments_position ALIGNMENTS_POSITION\n\n```\n\n## Usage examples CLI\n\nTo make a figure with default parameters:\n\n```bash\nmsplotter -i path/file_1.gb path/file_2.gb path/file_3.gb\n```\n\nTo save a figure in pdf format:\n\n```bash\nmsplotter -i path/file_1.gb path/file_2.gb path/file_3.gb -f pdf\n```\n\n## Notes\n\nI started this project to make a figure paper with three sequences with lengths\nbetween 8 to 23 kb. However, the matplotlib parameters can be adjusted for\nlarger, smaller, or more sequences.\n\n## Credits\n\nInspired by easyfig: Sullivan et al (2011) Bioinformatics 27(7):1009-1010\n\n## License\n\nBSD 3-Clause License\n",
    "bugtrack_url": null,
    "license": "BSD 3-Clause License",
    "summary": "Make a graphical representation of a blastn alignment",
    "version": "0.1.37",
    "project_urls": {
        "Homepage": "https://github.com/ivanmugu/MSPlotter"
    },
    "split_keywords": [
        "blast",
        "alignment",
        "graphical representation",
        "dna sequence",
        "easyfig"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "bc732ab0bc81b303777abbce0c4263efabd2440c914f65ba11e7dd5b5b6068d1",
                "md5": "7171fa9b0d6ab4809ef96efdf132b9c9",
                "sha256": "f42afce946d320271a4ec3ace441c98798a245ae1182ccb1edde80194a0520dd"
            },
            "downloads": -1,
            "filename": "msplotter-0.1.37-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "7171fa9b0d6ab4809ef96efdf132b9c9",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.11",
            "size": 420307,
            "upload_time": "2023-08-06T03:03:13",
            "upload_time_iso_8601": "2023-08-06T03:03:13.322899Z",
            "url": "https://files.pythonhosted.org/packages/bc/73/2ab0bc81b303777abbce0c4263efabd2440c914f65ba11e7dd5b5b6068d1/msplotter-0.1.37-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "4632605aae053e857bdfd45ab26818fb87a033ae73ac1b167d6732368e28509c",
                "md5": "63a94bb90a6a3dd3f7f9364b65e1a73b",
                "sha256": "40ec92eb39f4253aa10e4dd8db83d5624d06b31c722eebf40e3509edfe47f7bf"
            },
            "downloads": -1,
            "filename": "msplotter-0.1.37.tar.gz",
            "has_sig": false,
            "md5_digest": "63a94bb90a6a3dd3f7f9364b65e1a73b",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.11",
            "size": 415736,
            "upload_time": "2023-08-06T03:03:15",
            "upload_time_iso_8601": "2023-08-06T03:03:15.216389Z",
            "url": "https://files.pythonhosted.org/packages/46/32/605aae053e857bdfd45ab26818fb87a033ae73ac1b167d6732368e28509c/msplotter-0.1.37.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-08-06 03:03:15",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "ivanmugu",
    "github_project": "MSPlotter",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "lcname": "msplotter"
}
        
Elapsed time: 0.09453s