Instantly share code, notes, and snippets.

View README.md

OpenBioDiv query to get specimens from MNRJ

Query by Viktor Senderov:

"In order to illustrate the capabilities of OpenBiodiv and draw attention to the impact of the tragically lost collection of the Museu Nacional de Rio de Janeiro (MNRJ), I can ask our system to give me the number of times a specimen from that collection was used in a taxonomic article, and in which ones."

http://big4-project.eu/news/11665_blog-post-openbiodiv-the-semantic-web-comes-to-biodiversity-informatics/

See query at https://goo.gl/4ovg2o

View clements2017-2018.html
<html>
<head>
<style>
html, body{
width:100%;
height:100%;
font-size:14px;
}
#wrapper {
padding:1%;
View cltools.sh
#!/bin/sh
##
# Install autoconf, automake and libtool smoothly on Mac OS X.
# Newer versions of these libraries are available and may work better on OS X
#
# This script is originally from http://jsdelfino.blogspot.com.au/2012/08/autoconf-and-automake-on-mac-os-x.html
#
export build=~/devtools # or wherever you'd like to build
View jsonld.sh
curl -XDELETE 'localhost:9200/jsonld'
curl -XPOST 'localhost:9200/jsonld'
curl -XPUT 'localhost:9200/jsonld/doc/1' -d '
{
"@context":
{
"dc": "http://purl.org/dc/elements/1.1/",
View Multiple identifiers
== Handling multiple identifiers
Many objects of interest will have multiple identifiers, and each identifier may have different, complementary data associated with it.
One approach is to treat each identifier as a node, and link it to node for the corresponding object (essentially the object is treated as a bnode). We therefore refer to an object as "the object identifier by <identifier>". If we have correctly associated multiple identifiers with the same object, then we can link the two objects together.
When we have a link to create to another object, we use MERGE (id)-[]-(object) to ensure that id-object exists, then we link to it. In the example below we have a work with DOI 10.3897/phytokeys.44.7993, which cites PMID 21653447. First we create the work with DOI 10.3897/phytokeys.44.7993.
//hide
//setup
View query.txt
The Mediawiki API can be used to find qhat wikipedia pages link to BioStor, e.g.:
https://en.wikipedia.org/w/api.php?action=query&list=exturlusage&euquery=biostor.org&eulimit=20
See https://www.mediawiki.org/wiki/API:Lists/All#Exturlusage for details.
View Cricula.nexus
#NEXUS
Begin trees; [Treefile saved Thu Aug 20 21:42:14 2015]
[!
>Data file = /Users/rpage/Sites/geojson-phylogeny-demo/bold-api/service/tmp/SAUPA642-10/SAUPA642-10.nex
>Neighbor-joining search settings:
> Ties (if encountered) will be broken systematically
> Distance measure = uncorrected ("p")
> (Tree is unrooted)
]
View Cricula.geojson
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View primers.txt
Reference COI is NC_003128 Buteo buteo COI
TZBRD035-15.COI-5P [648bp] ctgatctttggtgnatgagcaggcatagccggcacagcacttagcctactaatccgcgcagaactaggacagccaggaacactattgggagacgaccaaatctacaatgtaatcgtaacagcccacgctttcgtcataatcttcttcatagtcatacctattatgatcggaggcttcggaaactgactggttccactcataattggcgccccagacatagcattcccccgcataaataatatgagcttctgactcctcccaccttcttttctcctcctactagcctcctctacagtagaagccggggctggcactggatgaactgtttatccacccctagccggtaatcttgcccacgcgggcgcatcagtagacctggctattttttcccttcacttggcaggcgtgtcgtccatcttaggagctattaactttatcaccacaattattaacataaagccccctgcactatcacaatatcaaacacccctcttcgtatgatccgtcctcattactgctatcctcttactactatccctgccagtcctagccgccgggattacaatactcctcaccgatcgcaacctcaacactacattctttgaccctgcaggaggaggagacccaatcctgtatcaacacctattc
TZBRD019-15.COI-5P tcttcggcgcctgagctggtatagtcggcaccgccctcagcttactcatccgtgcagaactcggccaacccggcacactcctaggtgacgaccaaatttataacgtaatcgttaccgcacatgccttcgtaataatcttcttcatagttataccaatcatgatcggaggattcggaaactgacttgttccactcataattggcgctc
View index.html
<!DOCTYPE html>
<html>
<head>
<title>GBIF search</title>
<meta charset="utf-8" />
<link
rel="stylesheet"
href="http://cdn.leafletjs.com/leaflet-0.7/leaflet.css"
/>
<link