The birth place of every pro wrestler (according to wikipedia)

By | October 29, 2014

A few days ago I mapped out the death places of Monarchs of England. I wanted to try the same technique on a bigger dataset and keeping on trend with some other stuff I’ve done with Reddit I decided to map the birthplace of every wrestler in Wikipedia.

This is a *rough* guide. It maps wrestlers birthplace to a random place somewhere in the city that Wikipedia says is their birthplace. If Wikpedia doesn’t think that the data is a city then the data is missing. This data is from a snapshot taken a few months ago. Also, Wikipedia has been known to be wrong,

Click a dot to see who was born there and you can drag the map and such. There are some other bits of info I should add and some bits I should remove, but for now this is it.

 

There were a few problems/differences

1)Google Fusion Tables doesn’t like it if you give it two lat+long values that are the same, I used this idea to get around that problem.

2)I changed my SPARQL query to only include citys

code:

install.packages('SPARQL')
library(SPARQL)
endpoint <- "http://live.dbpedia.org/sparql"
endpoint <- "http://dbpedia.org/sparql"
options <- NULL

query = "

PREFIX owl: <http://www.w3.org/2002/07/owl#>
PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX foaf: <http://xmlns.com/foaf/0.1/>
PREFIX dc: <http://purl.org/dc/elements/1.1/>
PREFIX : <http://dbpedia.org/resource/>
PREFIX dbpedia2: <http://dbpedia.org/property/>
PREFIX dbpedia: <http://dbpedia.org/>
PREFIX skos: <http://www.w3.org/2004/02/skos/core#>
PREFIX dbo: <http://dbpedia.org/ontology/>
PREFIX dbo: <http://dbpedia.org/ontology/>
PREFIX dcterms: <http://purl.org/dc/terms/>
PREFIX category: <http://dbpedia.org/resource/Category:>
prefix grs: <http://www.georss.org/georss/>

prefix grs: <http://www.georss.org/georss/>

SELECT ?person ?name ?born ?gps ?label WHERE {
?person rdf:type dbpedia-owl:Wrestler .
?person rdfs:label ?name
FILTER ( lang(?name) = 'en' ) .
?person dbpedia-owl:birthPlace ?born .
?born rdf:type dbpedia-owl:City .
?born grs:point ?gps .
?born rdfs:label ?label
FILTER(LANG(?label) = '' || LANGMATCHES(LANG(?label), 'en'))
}
"

qd <- SPARQL(endpoint,query)
df <- qd$results
write.csv(df, file = "wrestlersborn.csv")

 

 

Leave a Reply

Your email address will not be published. Required fields are marked *