Skip to content

Instantly share code, notes, and snippets.

View debpaul's full-sized avatar

Debbie Paul debpaul

View GitHub Profile
@debpaul
debpaul / findingSpecimenPreparationInformation.txt
Last active July 11, 2019 18:32
query iDigBio for preparationType information
Need: search of data where specimen "preparation" information exists.
Possibilities:
https://search.idigbio.org/v2/search/records/?rq={"data.dwc:dynamicProperties":["preparationType","preparation"]}
returns hits where the strings _preparationType_ or _preparation_ are found in the dynamicProperties data
currently returns over 200 records
note with this query - you could also search for strings like "alcohol" or similar
https://search.idigbio.org/v2/search/records/?rq={"data.dwc:preparations":{"type":"exists"}}
returns over 53M records where the field dwc:preparations is present
https://search.idigbio.org/v2/search/records/?rq={"family":["cyprinidae","ictaluridae"],"data.dwc:preparations":{"type":"exists"}}
returns now limited by family, returning records that have dwc:preparations for specimens with
@debpaul
debpaul / IndianaSpecimensSearchByInstitution.txt
Last active February 27, 2019 17:15
Search state=Indiana, group by institution code
https://search.idigbio.org/v2/summary/top/records/?top_fields=["institutioncode"]&rq={"stateprovince":"indiana"}&count=5000
This search request returns all specimens in the ADBC iDigBio portal where the state is "Indiana" and uses the Institution Code
as the anchor for the search. Output is in JSON.