User:MartinPoulter/queries/ee

Semantic Web of BooksEdit

Female historians in the EE born in the 1730s (selects Catharine Macaulay)Edit

The following query uses these:

Editions of works by Catharine Macaulay, and their online textEdit

Note: doesn't capture Wikisource transcriptions or Google Books links via Google Books ID (P675)

The following query uses these:

Digital versions of a work that the Oxford Text Archive has, but a different edition from the Oxford Text ArchiveEdit

The following query uses these:

  • Properties: edition or translation of (P629)     , full work available at URL (P953)     , publication date (P577)     , title (P1476)     , edition number (P393)     
     1 SELECT ?edition2 ?title ?year2 ?text2 ?this_is_no ?ota_has_no WHERE {
     2 ?edition1 wdt:P629 ?work; 
     3     wdt:P953 ?text1;
     4     wdt:P577 ?pubdate1.
     5 FILTER CONTAINS(STR(?text1),"ota.ox.ac.uk") # OTA scan of work
     6 BIND(YEAR(?pubdate1) as ?year) # publication year  
     7 ?edition2 wdt:P629 ?work; # edition of work
     8     wdt:P953 ?text2;
     9     wdt:P1476 ?title;
    10     wdt:P577 ?pubdate2.
    11 FILTER( ?edition1 != ?edition2 ) # non-OTA scan of work
    12 BIND(YEAR(?pubdate2) as ?year2) # publication year
    13 #FILTER{ ?year1 > ?year2 }
    14 OPTIONAL{ ?edition1 wdt:P393 ?ota_has_no } # edition number
    15 OPTIONAL{ ?edition2 wdt:P393 ?this_is_no }
    16 }
    

Biographies in the Plomer Dictionary of Booksellers and PrintersEdit

The following query uses these:

  • Properties: published in (P1433)     
    1 SELECT ?entry ?wslink WHERE {
    2   ?entry wdt:P1433 wd:Q40901539. # published in Plomer DBP
    3 OPTIONAL{ ?wslink schema:about ?entry; schema:isPartOf <https://en.wikisource.org/> }
    4 }
    

Types of editionEdit

MapsEdit

Map of birthplacesEdit

Lots of overlaps due to common birthplaces..

The following query uses these:

Features: Map (Q24515275)     

 1 #defaultView:Map
 2 SELECT ?name ?birthyear ?image (SAMPLE(?coord) AS ?coord) (URI(CONCAT("http://dx.doi.org/10.13051/ee:bio/", ?ee)) AS ?eelink)
 3 WHERE {
 4    ?person wdt:P3429 ?ee;
 5      wdt:P19 ?place;
 6      rdfs:label ?name filter (lang(?name) = "en").
 7    ?place wdt:P625 ?coord
 8    OPTIONAL { ?person wdt:P569 ?dob }
 9    BIND(CONCAT("Born ", STR(YEAR(?dob))) as ?birthyear)
10    OPTIONAL {?person wdt:P18 ?image }
11 } GROUP BY ?name ?image ?ee ?birthyear

Wikipedia articlesEdit

See also w:en:Wikipedia:OUP/Electronic_Enlightenment

EE items that have English Wikipedia articlesEdit

The following query uses these:

  • Properties: Electronic Enlightenment ID (P3429)     
    1 SELECT ?name (URI(CONCAT("http://dx.doi.org/10.13051/ee:bio/", ?ee)) AS ?eelink) ?englishwp
    2 WHERE {
    3 ?person wdt:P3429 ?ee;
    4         rdfs:label ?name filter (lang(?name) = "en")
    5 ?englishwp schema:about ?person; schema:isPartOf <https://en.wikipedia.org/>
    6 } ORDER BY ?ee
    

Note: as of 13 April 2017, 420 imported EE items lack English Wikipedia articles.

EE items that lack English Wikipedia articles, but have articles in another version of WikipediaEdit

The following query uses these:

  • Properties: Electronic Enlightenment ID (P3429)     
    1 SELECT ?person ?personLabel ?personDescription (URI(CONCAT("http://dx.doi.org/10.13051/ee:bio/", ?ee)) AS ?eelink)
    2 (GROUP_CONCAT(?otherwp) AS ?links)
    3 WHERE {
    4 ?person wdt:P3429 ?ee.
    5 MINUS {?englishwp schema:about ?person; schema:isPartOf <https://en.wikipedia.org/> }
    6 SERVICE wikibase:label {bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en,fr,de"}
    7 ?otherwp schema:about ?person
    8 FILTER CONTAINS(STR(?otherwp),"wikipedia") 
    9 } GROUP BY ?personLabel ?personDescription ?ee ?person ORDER BY ?ee
    

EE items with no article in any language version of Wikipedia, with optional links to texts that describe themEdit

The following query uses these:

  • Properties: Electronic Enlightenment ID (P3429)     , described by source (P1343)     
    1 SELECT ?person ?personLabel ?personDescription (URI(CONCAT("http://dx.doi.org/10.13051/ee:bio/", ?ee)) AS ?eelink) ?sourcename ?ws
    2 WHERE {
    3 ?person wdt:P3429 ?ee.
    4 SERVICE wikibase:label {bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en,fr,de"}
    5 MINUS {?wp schema:about ?person; FILTER CONTAINS(STR(?wp),"wikipedia")  }
    6 OPTIONAL { ?person p:P1343/ps:P1343 ?source. ?source rdfs:label ?sourcename filter (lang(?sourcename) = "en")
    7 OPTIONAL { ?ws schema:about ?source; schema:isPartOf <https://en.wikisource.org/> } }
    8 } ORDER BY ?ee
    

DepictionsEdit

Image galleryEdit

The following query uses these:

Features: ImageGrid (Q24515278)     

1 #defaultView:ImageGrid
2 SELECT ?personLabel ?personDescription ?image (URI(CONCAT("http://dx.doi.org/10.13051/ee:bio/", ?ee)) AS ?eelink)
3 WHERE {
4 ?person wdt:P3429 ?ee;
5    wdt:P18 ?image
6 SERVICE wikibase:label {bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en,fr,de,es,it,sv"}
7 } ORDER BY ?personLabel

EE people without images, including links to searches on the National Portrait GalleryEdit

The following query uses these:

Art depicting EE peopleEdit

Only shows art for which there is a freely available scan in Wikimedia Commons

The following query uses these:

OrganisationsEdit

Organisation membershipEdit

The following query uses these:

Features: BubbleChart (Q24515280)     

1 #defaultView:BubbleChart
2 SELECT ?orgname (COUNT(?person) AS ?members)
3 WHERE {
4    ?person wdt:P3429 [];
5      wdt:P463 ?org.
6     ?org rdfs:label ?orgname filter (lang(?orgname) = "en")
7 } GROUP BY ?orgname
8 ORDER BY DESC (?members)

Organisations and the individuals who are membersEdit

The following query uses these:

  • Properties: Electronic Enlightenment ID (P3429)     , member of (P463)     
    1 SELECT DISTINCT ?orgLabel ?person ?personLabel ?ee
    2 WHERE {
    3 ?person wdt:P3429 ?ee;
    4      wdt:P463 ?org
    5 SERVICE wikibase:label {bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en"}
    6 } ORDER BY ?orgLabel ?ee
    

Biographical factsEdit

Bubble chart of occupationsEdit

The following query uses these:

Features: BubbleChart (Q24515280)     

1 #defaultView:BubbleChart
2 SELECT ?jobname (COUNT(?person) AS ?members)
3 WHERE {
4    ?person wdt:P3429 ?ee;
5       wdt:P106 ?job.
6     ?job rdfs:label ?jobname filter (lang(?jobname) = "en")
7 } GROUP BY ?jobname
8 ORDER BY DESC (?members)

EE people not tagged with an occupation in WikidataEdit

The following query uses these:

Causes of deathEdit

The following query uses these:

Other identifiersEdit

UK National Archive IDsEdit

The following query uses these:

  • Properties: Electronic Enlightenment ID (P3429)     , UK National Archives ID (P3029)     
    1 SELECT ?person ?personLabel ?ee (URI(CONCAT("https://discovery.nationalarchives.gov.uk/details/c/",?natarch)) AS ?natarchlink)  WHERE {
    2 ?person wdt:P3429 ?ee;
    3   wdt:P3029 ?natarch
    4   SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en" }
    5 }
    6 ORDER BY ?personLabel
    

Project Gutenberg author IDsEdit

The following query uses these:

  • Properties: Electronic Enlightenment ID (P3429)     , Project Gutenberg author ID (P1938)     
    1 SELECT ?person ?personLabel ?ee (URI(CONCAT("https://www.gutenberg.org/ebooks/author/", ?gutenberg)) AS ?gutenberglink)  WHERE {
    2 ?person wdt:P3429 ?ee;
    3   wdt:P1938 ?gutenberg
    4   SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en" }
    5 }
    6 ORDER BY ?personLabel
    

Genealogics.org person IDsEdit

The following query uses these:

  • Properties: Electronic Enlightenment ID (P3429)     , genealogics.org person ID (P1819)     
    1 SELECT ?person ?personLabel ?ee (URI(CONCAT("http://www.genealogics.org/getperson.php?tree=LEO&personID=", ?gorg)) AS ?gorglink)  WHERE {
    2 ?person wdt:P3429 ?ee;
    3   wdt:P1819 ?gorg
    4   SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en" }
    5 }
    6 ORDER BY ?personLabel
    

History of Parliament IDEdit

The following query uses these:

  • Properties: Electronic Enlightenment ID (P3429)     , History of Parliament ID (P1614)     
    1 SELECT ?person ?personLabel ?ee (URI(CONCAT("http://www.historyofparliamentonline.org/volume/", ?parl)) AS ?parllink)  WHERE {
    2 ?person wdt:P3429 ?ee;
    3   wdt:P1614 ?parl
    4   SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en" }
    5 }
    6 ORDER BY ?personLabel
    

LettersEdit

Letters sent by EE entitiesEdit

The following query uses these:

  • Properties: author (P50)     , instance of (P31)     , Electronic Enlightenment ID (P3429)     
    1 SELECT ?author ?authorLabel ?letter ?letterLabel ?ws
    2 WHERE {
    3   ?letter wdt:P50 ?author;
    4    wdt:P31 wd:Q133492.
    5   ?author wdt:P3429 []
    6 OPTIONAL {?ws schema:about ?letter; schema:isPartOf <https://en.wikisource.org/> }
    7   SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en" }
    8 } ORDER BY ?authorLabel
    

Things addressed to EE entitiesEdit

The following query uses these:

  • Properties: addressee (P1817)     , Electronic Enlightenment ID (P3429)     
    1 SELECT ?recipient ?recipientLabel ?letter ?letterLabel ?ws
    2 WHERE {
    3   ?letter wdt:P1817 ?recipient.
    4     ?recipient wdt:P3429 []
    5   SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en" }
    6   OPTIONAL {?ws schema:about ?letter; schema:isPartOf <https://en.wikisource.org/> }
    7 } ORDER BY ?recipientLabel
    

Maintenance queriesEdit

Wikidata entities with EE IDsEdit

This highlights entities that have more than one EE ID, and also gives a total count.

The following query uses these:

  • Properties: Electronic Enlightenment ID (P3429)     
    1 SELECT ?person ?personLabel ?personDescription (COUNT(?ee) AS ?eelinks)
    2 WHERE {
    3    ?person wdt:P3429 ?ee
    4 SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en,fr,de,es" }
    5 } GROUP BY ?person ?personLabel ?personDescription
    6 ORDER BY DESC(?eelinks) ?ee