query-d94a1e88cc149df440b1e525785e01c8

rq turtle/ttl

(es decir, correspondientes a items con un buen número de artículos en Wikipedias) no en items, sino en artículos según su uso, clase la importancia de cada ponderarEn resumen, podemos

Use at

PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX schema: <http://schema.org/>
PREFIX bd: <http://www.bigdata.com/rdf#>
SELECT ?clase ?claseLabel (sum(?n_arts) as ?total) 
WHERE {
VALUES ?clase {wd:Q277759 wd:Q1585442}
  SERVICE wikibase:label { bd:serviceParam wikibase:language "es,en". } 
{
SELECT ?clase (count(?article) as ?n_arts) (count(?item) as ?n_items)  WHERE { 
VALUES ?clase {wd:Q277759 wd:Q1585442}
  ?item wdt:P31 ?clase.
  ?article schema:about ?item .
  FILTER (CONTAINS(str(?article),'wikipedia'))
  }
  GROUP BY ?clase
  ORDER BY DESC(?n_arts)
}
  }
GROUP BY ?clase ?claseLabel

Query found at

graph TD classDef projected fill:lightgreen; classDef literal fill:orange; classDef iri fill:yellow; v3("?article") v4("?clase"):::projected v4("?item") v5("?n_arts"):::projected v5("?n_items") v6("?total") c2(["bd:serviceParam"]):::iri c4(["es,en"]):::literal bind0[/VALUES ?clase/] bind0-->v4 bind00(["wd:Q277759"]) bind00 --> bind0 bind01(["wd:Q1585442"]) bind01 --> bind0 subgraph s1["http://wikiba.se/ontology#label"] style s1 stroke-width:4px; c2 --"wikibase:language"--> c4 end f1[["contains(str(?article),'wikipedia')"]] f1 --> v3 bind2[/VALUES ?clase/] bind2-->v4 bind20(["wd:Q277759"]) bind20 --> bind2 bind21(["wd:Q1585442"]) bind21 --> bind2 v4 --"wdt:P31"--> v4 v3 --"schema:about"--> v4 bind5[/"count(?article)"/] v3 --o bind5 bind5 --as--o v5 bind6[/"count(?item)"/] v4 --o bind6 bind6 --as--o v5 bind8[/"sum(?n_arts)"/] v5 --o bind8 bind8 --as--o v6