Skip to content

snickercop/python-mapbox

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 

Repository files navigation

python-mapbox

A library for using the Mapbox API in Python

List of Functions

points

geocode(place_name): returns the JSON result of a mapbox geocode call on the given string place_name.

get_coords(place_name): returns the coordinates of the given place_name as a list of form [longitude, latitude]

routing

All routing functions will take either list coordinate pairs (e.g. from distance.get_coords) or string place names.

distance(start, finish): returns the distance between two points in the preset preferred units. Optional third parameter is a string that denotes a mode of transit besides driving ('walking' or 'cycling')

multiDistance(pointA, pointC, pointD, pointB, profile='driving'): similar to distance. returns a list containing 0: the distance added to the A->B trip by adding the C->D trip and 1: the total distance of the multi-leg trip.

Installation

Run python3 -m pip install --index-url https://test.pypi.org/simple/ python-mapbox-snickercop

About

A library for using the Mapbox API in Python

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages