SPARQL Data Import

Allows to get data with SPARQL which is a RDF query language and protocol produced by the W3C RDF Data Access Working Group (DAWG)

1. Parameters

1.1 Endpoint

You can find list of SPARQL endpoint examples from this site.

From the list, copy an endpoint URL and paste it to endpoint Input Field. Or type in your endpoint URL.

For example, if you want to get data from DBPedia you can use http://dbpedia.org/sparql/ as your Endpoint URL.

1.2 Query

You can write a SPARQL Query in Query field. For example, if you want to query Universities in United States, you can write a query like this.

PREFIX dbpedia-owl: <http://dbpedia.org/ontology/>
PREFIX dbpedia: <http://dbpedia.org/resource/>
PREFIX dbpprop: <http://dbpedia.org/property/>

SELECT ?label ?homepage ?lat ?long ?endowment
WHERE {
  ?school a <http://schema.org/CollegeOrUniversity> 
  { ?school dbpedia-owl:country dbpedia:United_States }
  UNION
  { ?school dbpprop:country dbpedia:United_States }
  UNION 
  { ?school dbpprop:country "U.S."@en }
  UNION 
  { ?school dbpprop:country "United States"@en }

  OPTIONAL { ?school rdfs:label ?label .
             FILTER (LANGMATCHES(LANG(?label), 'en')) }
  OPTIONAL { ?school foaf:homepage ?homepage }
  OPTIONAL { ?school geo:lat ?lat ; geo:long ?long }
  OPTIONAL { ?school dbpedia-owl:endowment ?endowment }
}

You can find a list of SPARQL query example in this site

As for SPARQL syntax, please refer this site

2. Import

Once you confirmed the query result, click Import button to import the data as a data frame in Exploratory.

results matching ""

    No results matching ""