Created
June 12, 2016 07:27
-
-
Save kozo2/0f2403f777a5f3f8fc610c8084d63354 to your computer and use it in GitHub Desktop.
biohack16
This file contains hidden or 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
| library(SPARQL) # SPARQL querying package | |
| endpoint <- "http://www.ebi.ac.uk/rdf/services/biomodels/sparql" | |
| query <- | |
| " | |
| PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> | |
| PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#> | |
| PREFIX owl: <http://www.w3.org/2002/07/owl#> | |
| PREFIX xsd: <http://www.w3.org/2001/XMLSchema#> | |
| PREFIX dc: <http://purl.org/dc/elements/1.1/> | |
| PREFIX dcterms: <http://purl.org/dc/terms/> | |
| PREFIX foaf: <http://xmlns.com/foaf/0.1/> | |
| PREFIX skos: <http://www.w3.org/2004/02/skos/core#> | |
| PREFIX sbmlrdf: <http://identifiers.org/biomodels.vocabulary#> | |
| SELECT ?speciesid ?name WHERE { | |
| <http://identifiers.org/biomodels.db/BIOMD0000000001> sbmlrdf:species ?speciesid . | |
| ?speciesid sbmlrdf:name ?name} | |
| " | |
| qd <- SPARQL(endpoint,query) | |
| df <- qd$results |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment