Python library to visualize circular plasmid maps

Overview

Plasmidviewer

Plasmidviewer is a Python library to visualize plasmid maps from GenBank. This library provides only the function to visualize circular plasmids and doesn't provide functions to edit nucleotides and sequence features. If you want to do such operations, please use QUEEN, which I have recently developed. (In fact, this library is implemented based on the visualization function of QUEEN)

Installation

You can install this library using the following single command:
pip install git+https://github.com/ponnhide/plasmidviewer.git

Example code

= 0: facecolors.append("#FFDFDF") edgecolors.append("#EE0000") labelcolors.append("#DD0000") elif feat.type == "CDS" and feat.strand == -1: facecolors.append("#DFDFFF") edgecolors.append("#0000EE") labelcolors.append("#0000DD") else: edgecolors.append(None) labelcolors.append(None) facecolors.append(None) fig, ax = pv.visualize(record, feature_list=feats, title="lentiCas9-EGFP") fig.savefig("test1.pdf") fig, ax = pv.visualize(record, feature_list=feats, edgecolor=edgecolors, title="lentiCas9-EGFP") fig.savefig("test2.pdf") fig, ax = pv.visualize(record, feature_list=feats, facecolor=facecolors, edgecolor=edgecolors, labelcolor=labelcolors, title="lentiCas9-EGFP", inner_diameter=500, tick_interval=1000) fig.savefig("test3.pdf") ">
    import plasmidviewer as pv
    from Bio import SeqIO
    record = SeqIO.read("../example_data/addgene-plasmid-63592-sequence-334654.gbk", format="genbank") 
    feats  = []
    facecolors  = []
    edgecolors  = []
    labelcolors = [] 
    for feat in record.features:
        if feat.type == "source" or feat.type == "primer_bind":
            pass 
        else:
            feats.append(feat)  
            if feat.type == "CDS" and feat.strand >= 0:
                facecolors.append("#FFDFDF")
                edgecolors.append("#EE0000") 
                labelcolors.append("#DD0000") 

            elif feat.type == "CDS" and feat.strand == -1:
                facecolors.append("#DFDFFF")
                edgecolors.append("#0000EE") 
                labelcolors.append("#0000DD") 
            else:
                edgecolors.append(None)
                labelcolors.append(None)
                facecolors.append(None)

    fig, ax = pv.visualize(record, feature_list=feats, title="lentiCas9-EGFP")
    fig.savefig("test1.pdf")
    
    fig, ax = pv.visualize(record, feature_list=feats, edgecolor=edgecolors, title="lentiCas9-EGFP")
    fig.savefig("test2.pdf") 
    
    fig, ax = pv.visualize(record, feature_list=feats, facecolor=facecolors, edgecolor=edgecolors, labelcolor=labelcolors, title="lentiCas9-EGFP", inner_diameter=500, tick_interval=1000)
    fig.savefig("test3.pdf") 

Example images

You might also like...
Daily social mapping project in November 2021. Maps made using PyGMT whenever possible.
Daily social mapping project in November 2021. Maps made using PyGMT whenever possible.

Daily social mapping project in November 2021. Maps made using PyGMT whenever possible.

Deal with Bing Maps Tiles and Pixels / WGS 84 coordinates conversions, and generate grid Shapefiles

PyBingTiles This is a small toolkit in order to deal with Bing Tiles, used i.e. by Facebook for their Data for Good datasets. Install Clone this repos

Implemented a Google Maps prototype that provides the shortest route in terms of distance

Implemented a Google Maps prototype that provides the shortest route in terms of distance, the fastest route, the route with the fewest turns, and a scenic route that avoids roads when provided a source and destination. The algorithms used were DFS, BFS, A*, and Iterative Depth First Search.

Spectral decomposition for characterizing long-range interaction profiles in Hi-C maps

Inspectral Spectral decomposition for characterizing long-range interaction prof

Geocoding library for Python.

geopy geopy is a Python client for several popular geocoding web services. geopy makes it easy for Python developers to locate the coordinates of addr

Python interface to PROJ (cartographic projections and coordinate transformations library)
Python interface to PROJ (cartographic projections and coordinate transformations library)

pyproj Python interface to PROJ (cartographic projections and coordinate transformations library). Documentation Stable: http://pyproj4.github.io/pypr

PySAL: Python Spatial Analysis Library Meta-Package
PySAL: Python Spatial Analysis Library Meta-Package

Python Spatial Analysis Library PySAL, the Python spatial analysis library, is an open source cross-platform library for geospatial data science with

Python interface to PROJ (cartographic projections and coordinate transformations library)
Python interface to PROJ (cartographic projections and coordinate transformations library)

pyproj Python interface to PROJ (cartographic projections and coordinate transformations library). Documentation Stable: http://pyproj4.github.io/pypr

Python library to decrypt Airtag reports, as well as a InfluxDB/Grafana self-hosted dashboard example
Python library to decrypt Airtag reports, as well as a InfluxDB/Grafana self-hosted dashboard example

Openhaystack-python This python daemon will allow you to gather your Openhaystack-based airtag reports and display them on a Grafana dashboard. You ca

Owner
Mori Hideto
Mori Hideto
prettymaps - A minimal Python library to draw customized maps from OpenStreetMap data.

A small set of Python functions to draw pretty maps from OpenStreetMap data. Based on osmnx, matplotlib and shapely libraries.

Marcelo de Oliveira Rosa Prates 9k Jan 8, 2023
Python Data. Leaflet.js Maps.

folium Python Data, Leaflet.js Maps folium builds on the data wrangling strengths of the Python ecosystem and the mapping strengths of the Leaflet.js

null 6k Jan 2, 2023
python toolbox for visualizing geographical data and making maps

geoplotlib is a python toolbox for visualizing geographical data and making maps data = read_csv('data/bus.csv') geoplotlib.dot(data) geoplotlib.show(

Andrea Cuttone 976 Dec 11, 2022
Use Mapbox GL JS to visualize data in a Python Jupyter notebook

Location Data Visualization library for Jupyter Notebooks Library documentation at https://mapbox-mapboxgl-jupyter.readthedocs-hosted.com/en/latest/.

Mapbox 620 Dec 15, 2022
OSMnx: Python for street networks. Retrieve, model, analyze, and visualize street networks and other spatial data from OpenStreetMap.

OSMnx OSMnx is a Python package that lets you download geospatial data from OpenStreetMap and model, project, visualize, and analyze real-world street

Geoff Boeing 4k Jan 8, 2023
Google maps for Jupyter notebooks

gmaps gmaps is a plugin for including interactive Google maps in the IPython Notebook. Let's plot a heatmap of taxi pickups in San Francisco: import g

Pascal Bugnion 747 Dec 19, 2022
Solving the Traveling Salesman Problem using Self-Organizing Maps

Solving the Traveling Salesman Problem using Self-Organizing Maps This repository contains an implementation of a Self Organizing Map that can be used

Diego Vicente 3.1k Dec 31, 2022
Interactive Maps with Geopandas

Create Interactive maps ??️ with your geodataframe Geopatra extends geopandas for interactive mapping and attempts to wrap the goodness of amazing map

sangarshanan 46 Aug 16, 2022
Google Maps keeps old satellite imagery around for a while – this tool collects what's available for a user-specified region in the form of a GIF.

google-maps-at-88-mph The folks maintaining Google Maps regularly update the satellite imagery it serves its users, but outdated versions of the image

Noah Doersing 111 Sep 27, 2022
Location field and widget for Django. It supports Google Maps, OpenStreetMap and Mapbox

django-location-field Let users pick locations using a map widget and store its latitude and longitude. Stable version: django-location-field==2.1.0 D

Caio Ariede 481 Dec 29, 2022