Skip to content
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 5 additions & 4 deletions sparql/cell_by_location.rq
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
#+ summary: Find cells by location
#+ description: Enter an anatomical location, get back a list of cell type IRIs and labels
#+ summary: Find cells by type and location
#+ description: Args: cell: the iri or a cell type; location: the iri of an anatomical location. All args are optional. With no args returns all cells with an anatomical location. Returns: a 2 column table: cell (type) IRIs and cell (type) labels.

#+ defaults:
#+ - location: http://purl.obolibrary.org/obo/UBERON_0002113
#+ - location: http://purl.obolibrary.org/obo/UBERON_0001062 # Anatomical Entity
#+ - cell: http://purl.obolibrary.org/obo/CL_0000000 # Cell

PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX owl: <http://www.w3.org/2002/07/owl#>
Expand All @@ -12,7 +13,7 @@ PREFIX cell: <http://purl.obolibrary.org/obo/CL_0000000>
SELECT DISTINCT ?cell_iri (STR(?qlabel) as ?cell_label)
WHERE {
?cell_iri overlaps: ?_location_iri .
?cell_iri rdfs:subClassOf cell: .
?cell_iri rdfs:subClassOf ?_cell_iri .
?cell_iri rdfs:label ?qlabel .
}

Expand Down