Code examples: curl
PREFIX sbd: <https://www.sbd4nano.eu/rdf/#>
PREFIX sbdbel: <https://www.sbd4nano.eu/bel/#>
PREFIX npo: <http://purl.bioontology.org/ontology/npo#>
PREFIX sio: <http://semanticscience.org/resource/SIO_>
PREFIX sbdbel2: <https://h2020-sbd4nano.github.io/sbdbel/>
SELECT DISTINCT
?superclass (SAMPLE(?superclassLabel_) AS ?superclassLabel)
?nm (SAMPLE(?nmLabel_) AS ?nmLabel)
(COUNT(DISTINCT ?relation) AS ?relations)
WHERE {
VALUES ?ca { sbdbel:CausalAssertion sbd:CausalAssertion sbdbel2:CausalAssertion }
VALUES ?superclass { npo:NPO_1892 }
?nm rdfs:subClassOf* ?superclass ; rdfs:label ?nmLabel_ .
?superclass rdfs:label ?superclassLabel_ .
?relation a ?ca ; sbdbel:NP | sio:000332 | sbdbel2:NP ?nm .
} GROUP BY ?superclass ?nm
curl -s https://raw.githubusercontent.com/h2020-sbd4nano/sbd-data-book/master/sparql/allAgRelationships.rq | sed 's+<lang/>+en+' > allAgRelationships.rq
curl -H "Accept: text/tab-separated-values" -G https://sbd4nanolandscape.rdf.bigcat-bioinformatics.org/sparql --data-urlencode query@allAgRelationships.rq
This SPARQL query is available under CCZero.