sparql-examples

A set of SPARQL examples that are used in different SIB resources

View the Project on GitHub sib-swiss/sparql-examples

neXtProt/NXQ_00202

Proteins with from 2 to 4 transmembrane regions

Use at

PREFIX : <http://nextprot.org/rdf/>

SELECT DISTINCT ?entry WHERE {
 ?entry :isoform ?iso.
 ?iso :topology ?statement.
 ?statement a :TransmembraneRegion.
} group by ?entry ?iso having(count( ?statement)>=2 && count( ?statement)<=4)
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
  v4("?_anon_524857e97b124dceaa8a4ecc8d1a18274288")
  v5("?_anon_524857e97b124dceaa8a4ecc8d1a18274289")
  v1("?entry"):::projected 
  v2("?iso")
  v3("?statement")
  a1((" "))
  c6([":TransmembraneRegion"]):::iri 
  f0[[" >= '2^^xsd:integer' <= '4^^xsd:integer'"]]
  f0 --> a1
  v1 --":isoform"-->  v2
  v2 --":topology"-->  v3
  v3 --"a"-->  c6
  bind3[/"count(?statement)"/]
  v3 --o bind3
  bind3 --as--o v4
  bind4[/"count(?statement)"/]
  v3 --o bind4
  bind4 --as--o v5