query-6329de6bbd9efce570e2a6c9b9ed0843

rq turtle/ttl

مجمعة لكل بلدية على محور ص، متحركة حسب مجموعات نطاق المسافة الثابتة grouped per municipality on x-axis, animated by fixed dist range groups grouped per municipality on x-axis, animated by fixed dist range groups seskupené podle obcí na ose x, animované podle skupin s pevným rozsahem vzdáleností. grouped per municipality on x-axis, animated by fixed dist range groups gruppiert nach Gemeinde auf der x-Achse, animiert nach festen Distanzbereichen grouped per municipality on x-axis, animated by fixed dist range groups grouped per municipality on x-axis, animated by fixed dist range groups grouped per municipality on x-axis, animated by fixed dist range groups grouped per municipality on x-axis, animated by fixed dist range groups grouped per municipality on x-axis, animated by fixed dist range groups groupées par municipalité sur les abscisses, animé par intervalle donné de valeur de distance grouped per municipality on x-axis, animated by fixed dist range groups grouped per municipality on x-axis, animated by fixed dist range groups grouped per municipality on x-axis, animated by fixed dist range groups raggruppati per comune sull'asse delle ascisse, animati da gruppi a distanza fissa grouped per municipality on x-axis, animated by fixed dist range groups grouped per municipality on x-axis, animated by fixed dist range groups grouped per municipality on x-axis, animated by fixed dist range groups grouped per municipality on x-axis, animated by fixed dist range groups grouped per municipality on x-axis, animated by fixed dist range groups gegroepeerd per gemeente op x-as, geanimeerd door vaste afstandsgroepen grouped per municipality on x-axis, animated by fixed dist range groups grouped per municipality on x-axis, animated by fixed dist range groups grouped per municipality on x-axis, animated by fixed dist range groups grouped per municipality on x-axis, animated by fixed dist range groups grouped per municipality on x-axis, animated by fixed dist range groups grupperade efter kommun i en x-axel, animerade efter fixerad distansgrupper grouped per municipality on x-axis, animated by fixed dist range groups grouped per municipality on x-axis, animated by fixed dist range groups згруповані за муніципалітетами по осі x, анімовані за групами фіксованих діапазонів відстаней grouped per municipality on x-axis, animated by fixed dist range groups grouped per municipality on x-axis, animated by fixed dist range groups

Use at

PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX geof: <http://www.opengis.net/def/function/geosparql/>
PREFIX bd: <http://www.bigdata.com/rdf#>
#defaultView:ScatterChart
PREFIX var_muntype: <http://www.wikidata.org/entity/Q15284>
PREFIX var_area: <http://www.wikidata.org/entity/Q6308>
SELECT ?from (?distNum AS ?kilometers) ?to (?distGrp AS ?animation) WHERE {
  { SELECT ?mun (SAMPLE(?loc) AS ?loc)
    WHERE { ?mun wdt:P31/wdt:P279* var_muntype:;
                 wdt:P131 var_area:;
                 wdt:P625 ?loc. }
    GROUP BY ?mun
  }
  OPTIONAL {
    { SELECT (?mun AS ?mun2) (SAMPLE(?loc) AS ?loc2)
      WHERE { ?mun wdt:P31/wdt:P279* var_muntype:;
                   wdt:P131 var_area:;
                   wdt:P625 ?loc. }
      GROUP BY ?mun
    }
  }
  #FILTER (STR(?mun) <= STR(?mun2)).
  BIND(geof:distance(?loc, ?loc2) AS ?distNum).
  BIND(COALESCE(
    IF(?distNum >= 40, "40 km und mehr", 1/0),
    IF(?distNum >= 30, "30 - 40 km", 1/0),
    IF(?distNum >= 20, "20 - 30 km", 1/0),
    IF(?distNum >= 10, "10 - 20 km", 1/0),
    IF(?distNum >= 5, "05 - 10 km", 1/0),
    IF(?distNum >= 1, "01 - 05 km", "00 - 01 km")) AS ?distGrp).

  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],mul,en".
    ?mun rdfs:label ?from.
    ?mun2 rdfs:label ?to.
  }
}
ORDER BY ?animation ?from ?kilometers

Query found at

graph TD classDef projected fill:lightgreen; classDef literal fill:orange; classDef iri fill:yellow; v11("?animation") v9("?distGrp"):::projected v8("?distNum"):::projected v2("?from"):::projected v11("?kilometers") v6("?loc") v7("?loc2") v4("?mun") v6("?mun2") v10("?to"):::projected a1((" ")) a2((" ")) c5([http://www.wikidata.org/entity/Q6308]):::iri c8(["bd:serviceParam"]):::iri c3([http://www.wikidata.org/entity/Q15284]):::iri c10(["#91;AUTO_LANGUAGE#93;,mul,en"]):::literal v4 --"wdt:P31"--> a1 a1 --"wdt:P279"--> c3 v4 --"wdt:P131"--> c5 v4 --"wdt:P625"--> v6 bind1[/"sample(?loc)"/] v6 --o bind1 bind1 --as--o v6 subgraph optional0["(optional)"] style optional0 fill:#bbf,stroke-dasharray: 5 5; v4 -."wdt:P31".-> a2 a2 --"wdt:P279"--> c3 v4 --"wdt:P131"--> c5 v4 --"wdt:P625"--> v6 bind3[/"?mun"/] v4 --o bind3 bind3 --as--o v6 bind4[/"sample(?loc)"/] v6 --o bind4 bind4 --as--o v7 end bind5[/"http://www.opengis.net/def/function/geosparql/distance(?loc,?loc2)"/] v6 --o bind5 v7 --o bind5 bind5 --as--o v8 bind6[/"if(?distNum >= '40^^xsd:integer','40 km und mehr','1^^xsd:integer' / '0^^xsd:integer')if(?distNum >= '30^^xsd:integer','30 - 40 km','1^^xsd:integer' / '0^^xsd:integer')if(?distNum >= '20^^xsd:integer','20 - 30 km','1^^xsd:integer' / '0^^xsd:integer')if(?distNum >= '10^^xsd:integer','10 - 20 km','1^^xsd:integer' / '0^^xsd:integer')if(?distNum >= '5^^xsd:integer','05 - 10 km','1^^xsd:integer' / '0^^xsd:integer')if(?distNum >= '1^^xsd:integer','01 - 05 km','00 - 01 km')"/] v8 --o bind6 bind6 --as--o v9 subgraph s1["http://wikiba.se/ontology#label"] style s1 stroke-width:4px; c8 --"wikibase:language"--> c10 v4 --"rdfs:label"--> v2 v6 --"rdfs:label"--> v10 end bind7[/"?distNum"/] v8 --o bind7 bind7 --as--o v11 bind8[/"?distGrp"/] v9 --o bind8 bind8 --as--o v11