Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

In /missing page for award, add panel on publications with missing topics #845

Closed
Daniel-Mietchen opened this issue Oct 7, 2019 · 2 comments · Fixed by #984
Closed

In /missing page for award, add panel on publications with missing topics #845

Daniel-Mietchen opened this issue Oct 7, 2019 · 2 comments · Fixed by #984

Comments

@Daniel-Mietchen
Copy link
Member

similar to the one we have on a /missing page for authors

@Daniel-Mietchen
Copy link
Member Author

@egonw egonw added this to Frontend in Robustifying Scholia Oct 8, 2019
@Daniel-Mietchen
Copy link
Member Author

Daniel-Mietchen commented Dec 8, 2019

Here is a first go at this:

SELECT
?citations  ?work ?workLabel (?work AS ?wikidata_url)
WITH {
  SELECT (COUNT(?author) as ?count) ?work WHERE {
  # Works by author
    ?work wdt:P50 ?author .
  # Author who received an award
    ?author wdt:P166 wd:Q80061 .
  # Work does not have a main subject statement
    FILTER NOT EXISTS { ?work wdt:P921 ?topic . }
  }
  GROUP BY ?work
  ORDER BY DESC(?count)
  LIMIT 2000
} AS %works
WITH {
  SELECT (COUNT(?work1) as ?citations) ?work WHERE {
  INCLUDE %works
  # Works cited
    OPTIONAL { ?work1 wdt:P2860 ?work }.
  }
  GROUP BY ?work
  ORDER BY DESC(?citations)
  LIMIT 200
} AS %result
WHERE {
  INCLUDE %result
  
  # Label the results
  SERVICE wikibase:label { bd:serviceParam wikibase:language "en,da,de,es,fr,jp,nl,no,ru,sv,zh". }
}
ORDER BY DESC(?citations)

@Daniel-Mietchen Daniel-Mietchen added this to To do in Awards via automation Dec 8, 2019
@Daniel-Mietchen Daniel-Mietchen moved this from To do to In progress in Awards Dec 8, 2019
Awards automation moved this from In progress to Done Dec 8, 2019
Robustifying Scholia automation moved this from Frontend to Done Dec 8, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
P166-award-received Wikidata property P921-main-subject Wikidata property
Projects
Awards
  
Done
Development

Successfully merging a pull request may close this issue.

1 participant