Skip to content

Instantly share code, notes, and snippets.

@jvsoest
Last active December 4, 2017 13:34
Show Gist options
  • Save jvsoest/da3f4be380711ca51d92462b8818ed3b to your computer and use it in GitHub Desktop.
Save jvsoest/da3f4be380711ca51d92462b8818ed3b to your computer and use it in GitHub Desktop.
example_sparql
prefix roo: <http://www.cancerdata.org/roo/>
prefix ncit: <http://ncicb.nci.nih.gov/xml/owl/EVS/Thesaurus.owl#>
prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
prefix icd: <http://purl.bioontology.org/ontology/ICD10/>
prefix uo: <http://purl.obolibrary.org/obo/UO_>
SELECT *
WHERE {
?patient rdf:type ncit:C16960.
?patient roo:100008 ?disease.
?disease rdf:type icd:C20;
{
?disease roo:100243 ?clinTnmRes.
?clinTnmRes roo:100242 ?clinTnmTRes.
?clinTnmTRes rdf:type ?tStage.
FILTER (?tStage = ncit:C48705).
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment