Creates SVG maps from geojsons, shapefiles and geodataframes
Project description
svgmapper
svgmapper
generates SVG maps from .geojson
files, Esri shapefiles, and geopandas geodataframes.
Below is a bried overview of how to use svgmapper
and a description of its classes and methods.
Creating a map
from svgmapper import Map, Layer
Map(
name="Map of US and Canada",
css='map.css',
epsg='epsg:2163',
size=(504, 504),
layers=[
Layer(
name='usa-states',
path='north-america/usa-states.geojson'
),
Layer(
name='ca-provinces',
path='north-america/canada-provinces.geojson'
)
]
).save('north-america.svg')
The code snippet above initializes a new map object with the specified Layers
(the drawing order of which is determined by the Layer's index in the provided list). That Map is then
saved to the specified location in the save()
method. The output map looks like below:
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
svgmapper-0.1.8.tar.gz
(19.8 kB
view details)
Built Distribution
svgmapper-0.1.8-py3-none-any.whl
(20.6 kB
view details)
File details
Details for the file svgmapper-0.1.8.tar.gz
.
File metadata
- Download URL: svgmapper-0.1.8.tar.gz
- Upload date:
- Size: 19.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.7.1 CPython/3.11.7 Darwin/23.3.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 066af324bee4b1ffd6398c2c2699f8a01edc8574d75df37c9de50cebd42058dd |
|
MD5 | b1c367caf174f2c4f239aadcd18ab6d2 |
|
BLAKE2b-256 | ce0cf3c3105a36e56bcb9094462a16b76e22ebbd2ca12e9c28a75702b59b12ae |
File details
Details for the file svgmapper-0.1.8-py3-none-any.whl
.
File metadata
- Download URL: svgmapper-0.1.8-py3-none-any.whl
- Upload date:
- Size: 20.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.7.1 CPython/3.11.7 Darwin/23.3.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 461f29e3496dd96d321a6e01b7d7101a0f00674dfeac273956d745ee5ef26b58 |
|
MD5 | b2cb1e402ac33be1aa8c34cdd0453726 |
|
BLAKE2b-256 | 8ff60e45b1e05b1f4b0663c9b4987507a4e75020816c2e1b21fdd7b98b4dd00e |