This is a pre-production deployment of Warehouse, however changes made here WILL affect the production instance of PyPI.
Latest Version Dependencies status unknown Test status unknown Test coverage unknown
Project Description

A python client for the iDigBio iDigBio v2 API.

Installation

pip install idigbio

If you want to use the Pandas Data Frame interface you need to install pandas as well.

pip install idigbio pandas

Basic Usage

Returning JSON from the API.

import idigbio
api = idigbio.json()
json_output = api.search_records()

Returning a Pandas Data Frame.

import idigbio
api = idigbio.pandas()
pandas_output = api.search_records()

See the Search API docs for info about the endpoint parameters.

Examples

View a Record By UUID

import idigbio
api = idigbio.json()
record = api.view("records","1db58713-1c7f-4838-802d-be784e444c4a")

Search for a Record by scientific name

import idigbio
api = idigbio.json()
record_list = api.search_records(rq={"scientificname": "puma concolor"})

Search for Records that have images

import idigbio
api = idigbio.json()
record_list = api.search_records(rq={"scientificname": "puma concolor", "hasImage": True})

Search for a MediaRecords by record property

import idigbio
api = idigbio.json()
mediarecord_list = api.search_media(rq={"scientificname": "puma concolor", "hasImage": True})

Create a heat map for a genus

import idigbio
api = idigbio.json()
m = api.create_map(rq={"genus": "acer"}, t="geohash")
m.save_map_image("acer_map_geohash", 2)

Create a point map for a genus

import idigbio
api = idigbio.json()
m = api.create_map(rq={"genus": "acer"}, t="points")
m.save_map_image("acer_map_points", 2)

Create a zoomed in point map for a bounding box

import idigbio
api = idigbio.json()
bbox = {"type": "geo_bounding_box", "bottom_right": {"lat": 29.642979999999998, "lon": -82.00}, "top_left": {"lat": 29.66298, "lon": -82.35315800000001}}
m = api.create_map(
    rq={"geopoint": bbox}
)
m.save_map_image("test.png", None, bbox=bbox)

Create a summary of kingdom and phylum data

import idigbio
api = idigbio.json()
summary_data = api.top_records(fields=["kingdom", "phylum"])

Get the number of Records for a search by scientific name

import idigbio
api = idigbio.json()
count = api.count_records(rq={"scientificname": "puma concolor"})

Get the number of MediaRecords for a search by scientific name

import idigbio
api = idigbio.json()
count = api.count_media(rq={"scientificname": "puma concolor"})

Get the histogram of Collection Dates for a search by record property, for the last 10 years

import idigbio
api = idigbio.json()
histogram_data = api.datehist(
    rq={"scientificname": "puma concolor"},
    top_fields=["institutioncode"], min_date="2005-01-01")

Release History

0.8.1 (2016-08-29)

  • Send etag with file on upload to verify correctness

0.6.1 (2016-04-08)

** Changes **

  • Add media_type to upload functionality.

0.6.0 (2016-03-30)

Changes

  • Make pandas an extra requirements, update docs

New

  • Specify auth for api backend
  • Upload image capability (requires auth)

0.5.0 (2016-02-24)

Changes

  • Don’t exclude data.* fields if requested specifically
  • Fix stats and datehist api calls to respect parameters; param names changed to use python style and match server params.

0.4.3 (2016-02-23)

Bugfixes

  • no results no longer errs in the pandas client.
  • limit correctly limits to specified record, not next larger batch size

Miscellaneous

  • Clarify targetted python versions
Release History

Release History

0.8.1

This version

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.8.0

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.7.2

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.7.1

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.7.0

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.6.1

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.6.0

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.5.0

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.4.3

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.4.2

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.4.1

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.4.0

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.3.0

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.2.1

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

Download Files

Download Files

TODO: Brief introduction on what you do with files - including link to relevant help section.

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
idigbio-0.8.1.tar.gz (8.7 kB) Copy SHA256 Checksum SHA256 Source Aug 30, 2016

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS HPE HPE Development Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting