# gspatial_plot
![](https://gspatial-plot.readthedocs.io/en/latest/_images/logo.png)
[![License](https://shields.io/badge/license-MIT-green.svg)](https://opensource.org/licenses/MIT)
[![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)
[![Downloads](https://static.pepy.tech/badge/gspatial-plot)](https://pepy.tech/project/gspatial-plot)
[![Documentation Status](https://readthedocs.org/projects/gspatial-plot/badge/?version=latest)](https://gspatial-plot.readthedocs.io/en/latest/?badge=latest)
A geospatial plotting library built on top of geopandas. The aim of this library is to simplify generation of various geospatial plot and provide a simple interface to various commonly used geospatial plot types.
# Documentation
[Welcome to gspatial-plot’s documentation! — gspatial-plot 0.1.0a0 documentation](https://gspatial-plot.readthedocs.io/en/latest/index.html)
# Features
1. Simple API
2. Better defaults compared to vanilla geopandas plot
3. Customizations made simple
4. Compatible with other geopandas or matplotlib axis objects
5. Provides functions for plotting bubbleplots, cartograms, heatmaps, spikemaps and densityplots
# Installing
`pip install gspatial-plot`
# Usage
```python
import gspatial_plot as gsp
usa = gsp.us_states
usa = usa[
~usa["NAME"].isin(
[
"Hawaii",
"Guam",
"American Samoa",
"Commonwealth of the Northern Mariana Islands",
"Alaska",
]
)
]
gsp.randommap(usa, seed=3, annot=True, annot_column="NAME", figsize=(30, 30))
```
```python
gsp.shapeplot(usa, figsize=(15, 15))
```
```python
gsp.pointplot(usa_points, base=usa)
```
```python
gsp.choropleth(usa, "AWATER")
```
```python
gsp.bubblemap(usa, usa["AWATER"])
```
```python
gsp.cartogram(
usa,
"AWATER",
)
```
```python
gsp.densityplot(usa, clip=True, clip_factor=1.5)
```
```python
gsp.heatmap(usa, "AWATER")
```
```python
gsp.spikemap(usa, "AWATER")
```
```python
gsp.offline_static_basemap()
```
```python
gsp.offline_folium_basemap(crs="EPSG4326")
```
Raw data
{
"_id": null,
"home_page": "https://github.com/ambeelabs/gspatial_plot/",
"name": "gspatial-plot",
"maintainer": "",
"docs_url": null,
"requires_python": "",
"maintainer_email": "",
"keywords": "geospatial plot geopandas maps plotting graph folium",
"author": "Ambee",
"author_email": "",
"download_url": "https://files.pythonhosted.org/packages/25/92/a5a3f0710f21bd6efc21e4b69c7df6e89554ae581a30a598f1564da22e07/gspatial_plot-0.2.0.tar.gz",
"platform": null,
"description": "# gspatial_plot\n\n![](https://gspatial-plot.readthedocs.io/en/latest/_images/logo.png)\n\n[![License](https://shields.io/badge/license-MIT-green.svg)](https://opensource.org/licenses/MIT)\n[![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)\n[![Downloads](https://static.pepy.tech/badge/gspatial-plot)](https://pepy.tech/project/gspatial-plot)\n[![Documentation Status](https://readthedocs.org/projects/gspatial-plot/badge/?version=latest)](https://gspatial-plot.readthedocs.io/en/latest/?badge=latest)\n\nA geospatial plotting library built on top of geopandas. The aim of this library is to simplify generation of various geospatial plot and provide a simple interface to various commonly used geospatial plot types.\n\n# Documentation\n\n[Welcome to gspatial-plot\u2019s documentation! — gspatial-plot 0.1.0a0 documentation](https://gspatial-plot.readthedocs.io/en/latest/index.html)\n\n# Features\n\n1. Simple API\n\n2. Better defaults compared to vanilla geopandas plot\n\n3. Customizations made simple\n\n4. Compatible with other geopandas or matplotlib axis objects\n\n5. Provides functions for plotting bubbleplots, cartograms, heatmaps, spikemaps and densityplots\n\n# Installing\n\n`pip install gspatial-plot`\n\n# Usage\n\n```python\nimport gspatial_plot as gsp\n\nusa = gsp.us_states\n\n\nusa = usa[\n ~usa[\"NAME\"].isin(\n [\n \"Hawaii\",\n \"Guam\",\n \"American Samoa\",\n \"Commonwealth of the Northern Mariana Islands\",\n \"Alaska\",\n ]\n )\n]\n\n\ngsp.randommap(usa, seed=3, annot=True, annot_column=\"NAME\", figsize=(30, 30))\n```\n\n```python\ngsp.shapeplot(usa, figsize=(15, 15))\n```\n\n```python\ngsp.pointplot(usa_points, base=usa)\n```\n\n```python\ngsp.choropleth(usa, \"AWATER\")\n```\n\n```python\ngsp.bubblemap(usa, usa[\"AWATER\"])\n```\n\n```python\ngsp.cartogram(\n usa,\n \"AWATER\",\n)\n```\n\n```python\ngsp.densityplot(usa, clip=True, clip_factor=1.5)\n```\n\n```python\ngsp.heatmap(usa, \"AWATER\")\n```\n\n```python\ngsp.spikemap(usa, \"AWATER\")\n```\n\n```python\ngsp.offline_static_basemap()\n```\n\n```python\ngsp.offline_folium_basemap(crs=\"EPSG4326\")\n```\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "A geospatial plotting library built on top of geopandas.",
"version": "0.2.0",
"project_urls": {
"Homepage": "https://github.com/ambeelabs/gspatial_plot/"
},
"split_keywords": [
"geospatial",
"plot",
"geopandas",
"maps",
"plotting",
"graph",
"folium"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "fd4d14776178355163ff61ce4c9da0f6b7d47ccdfc136e8cfb54b116126fb452",
"md5": "2228ce7c41b3dad31fc0445fa49ef86f",
"sha256": "dfcdfdb660f1392a933342708c96b5eeff7e4ab0c64db56dd04b1c4039f7f16c"
},
"downloads": -1,
"filename": "gspatial_plot-0.2.0-py3-none-any.whl",
"has_sig": false,
"md5_digest": "2228ce7c41b3dad31fc0445fa49ef86f",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": null,
"size": 2167307,
"upload_time": "2023-07-28T07:50:56",
"upload_time_iso_8601": "2023-07-28T07:50:56.118114Z",
"url": "https://files.pythonhosted.org/packages/fd/4d/14776178355163ff61ce4c9da0f6b7d47ccdfc136e8cfb54b116126fb452/gspatial_plot-0.2.0-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "2592a5a3f0710f21bd6efc21e4b69c7df6e89554ae581a30a598f1564da22e07",
"md5": "368e6040c4533429587469b34a51f651",
"sha256": "0f36aedcde2fc69d3c2230bb622f759c9a852630774a778e727261140ada3af2"
},
"downloads": -1,
"filename": "gspatial_plot-0.2.0.tar.gz",
"has_sig": false,
"md5_digest": "368e6040c4533429587469b34a51f651",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 2151922,
"upload_time": "2023-07-28T07:51:00",
"upload_time_iso_8601": "2023-07-28T07:51:00.958265Z",
"url": "https://files.pythonhosted.org/packages/25/92/a5a3f0710f21bd6efc21e4b69c7df6e89554ae581a30a598f1564da22e07/gspatial_plot-0.2.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2023-07-28 07:51:00",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "ambeelabs",
"github_project": "gspatial_plot",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"requirements": [],
"lcname": "gspatial-plot"
}