{ "info": { "author": "Bart R\u00f6mgens", "author_email": "bart.romgens@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 4 - Beta", "Intended Audience :: Developers", "License :: OSI Approved :: MIT License", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.4", "Programming Language :: Python :: 3.5", "Programming Language :: Python :: 3.6", "Programming Language :: Python :: 3.7" ], "description": "# geojsoncontour\n[![Build Status](https://travis-ci.org/bartromgens/geojsoncontour.svg?branch=master)](https://travis-ci.org/bartromgens/geojsoncontour) [![PyPI version](https://badge.fury.io/py/geojsoncontour.svg)](https://badge.fury.io/py/geojsoncontour) [![Coverage Status](https://coveralls.io/repos/github/bartromgens/geojsoncontour/badge.svg?branch=master)](https://coveralls.io/github/bartromgens/geojsoncontour?branch=master) \nA Python 3 module to convert matplotlib contour plots to geojson. Supports both contour and contourf plots.\n\nDesigned to show geographical [contour plots](http://matplotlib.org/examples/pylab_examples/contour_demo.html), \ncreated with [matplotlib/pyplot](https://github.com/matplotlib/matplotlib), as vector layer on interactive slippy maps like [OpenLayers](https://github.com/openlayers/ol3) and [Leaflet](https://github.com/Leaflet/Leaflet).\n\nDemo project that uses geojsoncontour: [climatemaps.romgens.com](http://climatemaps.romgens.com)\n\n![geojson contour demo usage](https://raw.githubusercontent.com/bartromgens/geojsoncontour/master/data/example_climatemaps.png)\n\n## Installation\nInstall with pip,\n```\n$ pip install geojsoncontour\n```\n\n## Usage\n\nUse `contour_to_geojson` to create a geojson with contour lines from a `matplotlib.contour` plot (not filled).\nUse `contourf_to_geojson` to create a geojson with filled contours from a `matplotlib.contourf` plot.\n\n### Contour plot to geojson\n```python\nimport numpy\nimport matplotlib.pyplot as plt\nimport geojsoncontour\n\n# Create contour data lon_range, lat_range, Z\n\n\n# Create a contour plot plot from grid (lat, lon) data\nfigure = plt.figure()\nax = figure.add_subplot(111)\ncontour = ax.contour(lon_range, lat_range, Z, cmap=plt.cm.jet)\n\n# Convert matplotlib contour to geojson\ngeojson = geojsoncontour.contour_to_geojson(\n contour=contour,\n ndigits=3,\n unit='m'\n)\n```\nFor filled contour plots (`matplotlib.contourf`) use `contourf_to_geojson`.\nSee [example_contour.py](examples/example_contour.py) and [example_contourf.py](examples/example_contourf.py) for simple but complete examples.\n\n### Show the geojson on a map\nAn easy way to show the generated geojson on a map is the online geojson renderer [geojson.io](http://geojson.io) or [geojson.tools](http://geojson.tools).\n\n### Style properties\nStroke color and width are set as geojson properties following https://github.com/mapbox/simplestyle-spec.\n\n### Create geojson tiles\nTry [geojson-vt](https://github.com/mapbox/geojson-vt) or [tippecanoe](https://github.com/mapbox/tippecanoe) if performance is an issue and you need to tile your geojson contours.\n\n\n## Tests\n\nRun all tests,\n```\npython -m unittest discover\n```\n\n\n", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "http://github.com/bartromgens/geojsoncontour", "keywords": "contour plot geojson pyplot matplotlib gis map", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "geojsoncontour", "package_url": "https://pypi.org/project/geojsoncontour/", "platform": "", "project_url": "https://pypi.org/project/geojsoncontour/", "project_urls": { "Homepage": "http://github.com/bartromgens/geojsoncontour" }, "release_url": "https://pypi.org/project/geojsoncontour/0.3.2/", "requires_dist": [ "geojson", "numpy", "matplotlib", "xarray" ], "requires_python": "", "summary": "Convert matplotlib contour plots to geojson", "version": "0.3.2" }, "last_serial": 5881324, "releases": { "0.1.0": [ { "comment_text": "", "digests": { "md5": "e2bef0586f1206836f6842eab4a245c7", "sha256": "b87f980e565eb3198d09808f647f5a97cf83fc14a4b4b5f47d63ff76c23055a7" }, "downloads": -1, "filename": "geojsoncontour-0.1.0.tar.gz", "has_sig": false, "md5_digest": "e2bef0586f1206836f6842eab4a245c7", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3174, "upload_time": "2016-05-03T01:24:57", "url": "https://files.pythonhosted.org/packages/eb/f9/f70c486fdfaa42671aa16b09df6272ceb69a328f15f989f9d4f861f1f73d/geojsoncontour-0.1.0.tar.gz" } ], "0.1.1": [ { "comment_text": "", "digests": { "md5": "01dfae93a9802afd49cbe13b084b72d3", "sha256": "1aeae157a32d763b4375e2bf6e2cf879b9e309a87c0885da90a317970e6bd726" }, "downloads": -1, "filename": "geojsoncontour-0.1.1.tar.gz", "has_sig": false, "md5_digest": "01dfae93a9802afd49cbe13b084b72d3", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3476, "upload_time": "2016-05-03T11:08:37", "url": "https://files.pythonhosted.org/packages/22/19/2c4aff4ef8c20265447a4df6636d0f4ace200a33adfd5a4933e36f263af2/geojsoncontour-0.1.1.tar.gz" } ], "0.1.2": [ { "comment_text": "", "digests": { "md5": "7c206610f945dd6aa3971f40ba824503", "sha256": "06de1a98be155b1bdba96a27964b531ca4c430846046564b8889b129f8ee1023" }, "downloads": -1, "filename": "geojsoncontour-0.1.2-py3-none-any.whl", "has_sig": false, "md5_digest": "7c206610f945dd6aa3971f40ba824503", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 5472, "upload_time": "2017-04-02T16:46:37", "url": "https://files.pythonhosted.org/packages/b6/e3/46ec6fb0dab0d8c2e0dd926bb04401fb235b374ffbd9be1d1f2963c6e9c5/geojsoncontour-0.1.2-py3-none-any.whl" } ], "0.1.3": [ { "comment_text": "", "digests": { "md5": "3dea6eacfa14150813730a5ed50e001a", "sha256": "a22047f95ccc3de2a7b2d72be9f9418a0224322b86f4ec862e8f56ca71471bd7" }, "downloads": -1, "filename": "geojsoncontour-0.1.3-py3-none-any.whl", "has_sig": false, "md5_digest": "3dea6eacfa14150813730a5ed50e001a", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 5484, "upload_time": "2017-09-06T12:26:28", "url": "https://files.pythonhosted.org/packages/4f/33/35fe73bdef31b84cdcf53fc1b0800a0425dce9ee4ab701951ad6f50933c4/geojsoncontour-0.1.3-py3-none-any.whl" } ], "0.1.4": [ { "comment_text": "", "digests": { "md5": "2795783cd072c6754c8e9bcb717c8af3", "sha256": "6c5f9b9ca0cb3cb12a3e7fcdef98ca83555c356ef6270bd3a8a41551661d9b1c" }, "downloads": -1, "filename": "geojsoncontour-0.1.4-py3-none-any.whl", "has_sig": false, "md5_digest": "2795783cd072c6754c8e9bcb717c8af3", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 5303, "upload_time": "2017-09-30T13:03:18", "url": "https://files.pythonhosted.org/packages/37/ce/27f6bce1d8f6afb32fc1741aba7e3bfa869d54ce2d8bd3ee1cf7171992bf/geojsoncontour-0.1.4-py3-none-any.whl" } ], "0.2.0": [ { "comment_text": "", "digests": { "md5": "fa84962684a0615c8012a339da76de98", "sha256": "1f426281407bf944a4621b18a9b9bda7912d65e24268e203fcc9e59547fb9d3a" }, "downloads": -1, "filename": "geojsoncontour-0.2.0-py3-none-any.whl", "has_sig": false, "md5_digest": "fa84962684a0615c8012a339da76de98", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 5814, "upload_time": "2018-03-09T15:33:41", "url": "https://files.pythonhosted.org/packages/99/3b/3977794d9137286d912146fb2a0faa48b65b9ae32194f10061c4f05158da/geojsoncontour-0.2.0-py3-none-any.whl" } ], "0.2.1": [ { "comment_text": "", "digests": { "md5": "aba2a5f556b1528e0cb9594a23a76a7a", "sha256": "8eb6b2092adae28e9bd8d184da01cf22e425f18164e15432bcf3fc6a23cfd118" }, "downloads": -1, "filename": "geojsoncontour-0.2.1-py3-release-any.whl", "has_sig": false, "md5_digest": "aba2a5f556b1528e0cb9594a23a76a7a", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 8170, "upload_time": "2018-03-28T21:33:17", "url": "https://files.pythonhosted.org/packages/fd/08/24a58eb329126dad04b7010a1132dd4fa653aaec348cd3c28484289a0949/geojsoncontour-0.2.1-py3-release-any.whl" } ], "0.3.0": [ { "comment_text": "", "digests": { "md5": "1eb6563dbd11b7f26b982241be937fab", "sha256": "eadcd85d837ec5468404dcdbfc6a489beb819d59ee33aacaa27fa3917ce412f6" }, "downloads": -1, "filename": "geojsoncontour-0.3.0-py3-none-any.whl", "has_sig": false, "md5_digest": "1eb6563dbd11b7f26b982241be937fab", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 8166, "upload_time": "2018-04-06T11:03:55", "url": "https://files.pythonhosted.org/packages/b7/2b/565e28bf93042c69b20aff0c11763f5ee6f08fd599918e8695f6a85e3f01/geojsoncontour-0.3.0-py3-none-any.whl" } ], "0.3.1": [ { "comment_text": "", "digests": { "md5": "89797429bd865164cb67fa3caffb7002", "sha256": "a1d8dd6b3c2b011465b0467201e979b8e680eb55e3c6d4f7cc5fe3e551aab747" }, "downloads": -1, "filename": "geojsoncontour-0.3.1-py3-none-any.whl", "has_sig": false, "md5_digest": "89797429bd865164cb67fa3caffb7002", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 7124, "upload_time": "2019-09-14T08:56:14", "url": "https://files.pythonhosted.org/packages/9c/ee/8ef2c09bfa724246148e0f1c9761639aad95120521d0bd4a681efd3e0ed4/geojsoncontour-0.3.1-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "969c8a7b38c38ce79db1c26602a79323", "sha256": "97686689aa15635ba11f7875b234fd6a90510431a37c0b01703aac24847b5031" }, "downloads": -1, "filename": "geojsoncontour-0.3.1.tar.gz", "has_sig": false, "md5_digest": "969c8a7b38c38ce79db1c26602a79323", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5123, "upload_time": "2019-09-14T08:56:15", "url": "https://files.pythonhosted.org/packages/5e/f7/9451161ad67df96f7c68af87f31d4fce79f557f5fad75a65669593ad5b13/geojsoncontour-0.3.1.tar.gz" } ], "0.3.2": [ { "comment_text": "", "digests": { "md5": "7ebcd7282f490cf6b4c195c2b343d676", "sha256": "0d815b77e703ce94e8c543a2ed5ac955e1a7c7bba3777af642dbf6406153c93f" }, "downloads": -1, "filename": "geojsoncontour-0.3.2-py3-none-any.whl", "has_sig": false, "md5_digest": "7ebcd7282f490cf6b4c195c2b343d676", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 6996, "upload_time": "2019-09-24T18:34:38", "url": "https://files.pythonhosted.org/packages/fb/c0/8cf5be306d3a7e63f64b338971bc0a1cab2d3fd3dd8573032b1790dbd3b7/geojsoncontour-0.3.2-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "02ab490064ac954cc1cdf3fd80bb5272", "sha256": "1e7efb643e46fffb17371ca851ad1617e59ce367870ad688cbbfdcf4cedc73f4" }, "downloads": -1, "filename": "geojsoncontour-0.3.2.tar.gz", "has_sig": false, "md5_digest": "02ab490064ac954cc1cdf3fd80bb5272", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4969, "upload_time": "2019-09-24T18:34:39", "url": "https://files.pythonhosted.org/packages/a3/64/15fd0d400b8140865be65d52d67caadaf2fa711e2add7ea5daee9330c37b/geojsoncontour-0.3.2.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "7ebcd7282f490cf6b4c195c2b343d676", "sha256": "0d815b77e703ce94e8c543a2ed5ac955e1a7c7bba3777af642dbf6406153c93f" }, "downloads": -1, "filename": "geojsoncontour-0.3.2-py3-none-any.whl", "has_sig": false, "md5_digest": "7ebcd7282f490cf6b4c195c2b343d676", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 6996, "upload_time": "2019-09-24T18:34:38", "url": "https://files.pythonhosted.org/packages/fb/c0/8cf5be306d3a7e63f64b338971bc0a1cab2d3fd3dd8573032b1790dbd3b7/geojsoncontour-0.3.2-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "02ab490064ac954cc1cdf3fd80bb5272", "sha256": "1e7efb643e46fffb17371ca851ad1617e59ce367870ad688cbbfdcf4cedc73f4" }, "downloads": -1, "filename": "geojsoncontour-0.3.2.tar.gz", "has_sig": false, "md5_digest": "02ab490064ac954cc1cdf3fd80bb5272", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4969, "upload_time": "2019-09-24T18:34:39", "url": "https://files.pythonhosted.org/packages/a3/64/15fd0d400b8140865be65d52d67caadaf2fa711e2add7ea5daee9330c37b/geojsoncontour-0.3.2.tar.gz" } ] }