Text
PREFIX atu-type: <http://publications.europa.eu/resource/authority/atu-type/>
PREFIX cv:       <http://data.europa.eu/m8g/>
PREFIX foaf:     <http://xmlns.com/foaf/0.1/>
PREFIX sioc:     <http://rdfs.org/sioc/ns#>
PREFIX skos:     <http://www.w3.org/2004/02/skos/core#>

SELECT DISTINCT ?county
WHERE
  { GRAPH ?graph
      { ?doc  sioc:has_container  $this ;
              foaf:primaryTopic   ?county .
        ?county  cv:level        atu-type:LTU_APS ;
                 skos:prefLabel  ?name .
      }
  }
ORDER BY ?name
Title
Countiesen
Apskrityslt
Category variable name
apskritis
Chart type
Series variable name
be_gatviu_proc
Title
Settlements without streetsen
Gyvenamosios vietovės be gatviųlt
Text
PREFIX atu:  <http://publications.europa.eu/resource/authority/atu-type/>
PREFIX cv:   <http://data.europa.eu/m8g/>
PREFIX dct:  <http://purl.org/dc/terms/>
PREFIX skos: <http://www.w3.org/2004/02/skos/core#>

# Settlements (the gyvenamoji-vietove level) climb dct:isPartOf to their county; a
# settlement "has streets" when any street (dct:Location) is dct:isPartOf it.
SELECT ?apskritis (ROUND(1000 * (1 - SUM(?withStreets) / COUNT(?settlement))) / 10 AS ?be_gatviu_proc)
WHERE
{
    GRAPH ?settlementGraph
    {
        ?settlement cv:level ?level ;
            dct:isPartOf ?parent .
    }
    FILTER(STRENDS(STR(?level), "/admin-unit-levels/gyvenamoji-vietove/#this"))
    # the parent is a municipality, or an eldership one level below it
    {
        GRAPH ?parentGraph { ?parent dct:isPartOf ?county }
    }
    UNION
    {
        GRAPH ?parentGraph { ?parent dct:isPartOf ?municipality }
        GRAPH ?municipalityGraph { ?municipality dct:isPartOf ?county }
    }
    GRAPH ?countyGraph
    {
        ?county cv:level atu:LTU_APS ;
            skos:prefLabel ?apskritis .
    }
    BIND(IF(EXISTS { GRAPH ?streetGraph { ?street a dct:Location ; dct:isPartOf ?settlement } }, 1, 0) AS ?withStreets)
}
GROUP BY ?apskritis
ORDER BY DESC(?be_gatviu_proc)
Title
Share of settlements without streets per countyen
Gyvenamųjų vietovių be gatvių dalis pagal apskritįlt