Skip to main content

Calculate the area inside of any GeoJSON geometry. This is a port of Mapbox'sgeojson-area for Python

Project description

https://travis-ci.org/scisco/area.svg?branch=develop https://badge.fury.io/py/area.svg

Calculate the area inside of any GeoJSON geometry. This is a port of Mapbox’s geojson-area for Python.

Installation

$ pip install area

Usage

Simply pass a geojson string or python dictionary to the area function and get the area.

>>> from area import area
>>> obj = {'type':'Polygon','coordinates':[[[-180,-90],[-180,90],[180,90],[180,-90],[-180,-90]]]}
>>> area(obj)
511207893395811.06

Test

$ python test.py

Credit

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

area-1.1.1.tar.gz (4.1 kB view hashes)

Uploaded Source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page