Difference between revisions of "GW150914"

From BITPlan Wiki
Jump to navigation Jump to search
Line 9: Line 9:
 
#
 
#
 
# select the events
 
# select the events
SELECT ?event ?catalogCode ?discovery ?eventLabel ?duration ?article  
+
SELECT ?event ?catalogCode ?discovery ?eventLabel ?duration ?lodurl ?article  
 
WHERE  
 
WHERE  
 
{
 
{
Line 37: Line 37:
 
   OPTIONAL {
 
   OPTIONAL {
 
     ?event wdt:P2047 ?duration
 
     ?event wdt:P2047 ?duration
 +
  } 
 +
 
 +
  # and might have a linked open data url
 +
  # https://www.wikidata.org/wiki/Property:P973
 +
  OPTIONAL {
 +
    ?event wdt:P973 ?lodurl
 
   }   
 
   }   
 
    
 
    

Revision as of 09:28, 17 October 2018

WikiData Query

try it!

# Find Gravitational wave events
# Created 2018-10-16 by Wolfgang Fahl BITPlan GmbH
#
# select the events
SELECT ?event ?catalogCode ?discovery ?eventLabel ?duration ?lodurl ?article 
WHERE 
{
  # any subject
  # which is an instance of
  # https://www.wikidata.org/wiki/Property:P31
  
  # gravitational wave event
  # https://www.wikidata.org/wiki/Q24748034
  ?event wdt:P31 wd:Q24748034.
  
  # and might hava catalog code
  # https://www.wikidata.org/wiki/Property:P528
  # catalog Code
  OPTIONAL {
    ?event wdt:P528 ?catalogCode
  }
  
  # and might have a time of discovery
  # https://www.wikidata.org/wiki/Property:P575
  OPTIONAL {
    ?event wdt:P575 ?discovery
  }   
  
  # and might have a time duration
  # https://www.wikidata.org/wiki/Property:P2047
  OPTIONAL {
    ?event wdt:P2047 ?duration
  }   
  
  # and might have a linked open data url
  # https://www.wikidata.org/wiki/Property:P973
  OPTIONAL {
    ?event wdt:P973 ?lodurl
  }   
  
  # show the Labels (e.g. eventLabel)
  SERVICE wikibase:label {               # ... include the labels
        bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en"
  }
  
  # the event might have an english wikipedia article
  OPTIONAL {
      ?article schema:about ?event .
      ?article schema:inLanguage "en" .
      FILTER (SUBSTR(str(?article), 1, 25) = concat("https://en.wikipedia.org/"))
  }
}
order by ?discovery

GW150914

GW151226

GW170104

GW170608

GW170814

GW170817

Open Data

O3