Last active
August 15, 2016 15:09
-
-
Save jhpoelen/17426f10a55133a67298951c77daf24a to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
rglobi::query('START predatorTaxon = node:taxons(name="Homo sapiens") | |
MATCH predatorTaxon<-[:CLASSIFIED_AS]-predator-[:ATE|PREYS_ON]->prey-[:CLASSIFIED_AS]->preyTaxon, | |
predator-[:COLLECTED_AT]->location-[:HAS_ENVIRONMENT]->envo | |
WHERE envo.name= "coast" | |
WITH envo, preyTaxon, predatorTaxon | |
MATCH preyTaxon<-[:CLASSIFIED_AS]-pred2-[:ATE]->prey2-[:CLASSIFIED_AS]->preyOfPreyTaxon | |
RETURN envo.externalId, envo.name, preyTaxon.commonNames?, preyTaxon.path?, predatorTaxon.name as predatorName, preyTaxon.name as preyName, count(distinct preyOfPreyTaxon.name) as preyOfPreyCount') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment