Skip to content
CDiGallo edited this page Oct 28, 2024 · 27 revisions

Lindas

Predicates use for Sorting

Current usage of predicates on the observations used to propose sorting on in visualize.admin.ch:

  • schema:name -> Name / Nom / Name
  • schema:identifier -> Identifikation / identifient / Identifier
  • schema:alternateName -> Abkürzung / abréviation / Abbreviation

To specify the order of values in a dimension one can use schema:order. For example to specify which value in an ordinal scale is lower than another. Example in Cube-Creator (EIAM access required) and on LINDAS

Opendata.swiss Categories

The categories defined by opendata.swiss are reflected and used through https://register.ld.admin.ch/opendataswiss/category

BAFU Specific Categories

BAFU Specific Categories are based on https://register.ld.admin.ch/foen/theme

visualize.admin.ch

Specifics for GeoShapes in Lindas / geo.ld.admin.ch

Dimensions with a meta:dataKind attached schema:GeoShape need a geo:hasGeometry per entry attached (e.g. https://ld.admin.ch/dimension/bgdi/biota/productionregions/4), pointing to the corresponding entry (e.g. https://geo.ld.admin.ch/biota/productionregion/geometry/4) on the Swisstopo Endpoint reachable per SPARQL on https://geo.ld.admin.ch/query.

Needed attributes that a cube shows up on visualize.admin.ch

Based on https://github.com/zazuko/rdf-cube-schema-viz/blob/master/README.md#version-history-of-cubes it is necessary to attache to the cube

  1. A schema:creativeWorkStatus to the cube, possible choices are:

    <cube> schema:creativeWorkStatus <https://ld.admin.ch/vocabulary/CreativeWorkStatus/Draft>
    <cube> schema:creativeWorkStatus <https://ld.admin.ch/vocabulary/CreativeWorkStatus/Published>
    
  2. A schema:workExample to the cube as follows:

    <cube> schema:workExample <https://ld.admin.ch/application/visualize>
    
  3. A schema:hasPart , and type schema:CreativeWork to the cube parent:

    <parent> a schema:CreativeWork.
    <parent> schema:hasPart <cube>.
    

Needed attributes that a cube shows up on opendata.swiss

  1. A schema:creativeWorkStatus to the cube:

    <cube> schema:creativeWorkStatus <https://ld.admin.ch/vocabulary/CreativeWorkStatus/Published>
    
  2. A schema:workExample to the cube as follows:

    <cube> schema:workExample <https://ld.admin.ch/application/opendataswiss>
    
  3. Per opendata.swiss Organisation a new harvester needs to added to opendata.swiss CKAN.

Expiration of old cubes by newer ones

Upon publication of a new version of a cube the legacy versions feature an additional property to inform the above Tools of its expiration.

<cube> schema:expires ?dateTimeOfUpdate

To filter for the latest published version of a cube a SPARQL query typically includes

<parent> schema:hasPart ?cube .
?cube a cube:Cube .
?cube schema:creativeWorkStatus <https://ld.admin.ch/vocabulary/CreativeWorkStatus/Published> .
FILTER( NOT EXISTS { ?cube schema:expires ?ex . } )

Publishing profile for new organizations

An organization may request its publishing profile for cube creator by opening an issue and providing the following information:

  • A short identifier. The identifier should be the English abbreviation of the organization. It will be used in namespaces hence the guidelines allow only lowercase letters.

  • A label in multiple languages. The required languages are English, German, French and Italian.

  • The subject. One of the theme-based subdomains of ld.admin.ch.

  • The organization IRI. It will be used as the default value in cubes for the property cube:observedBy. It may be an office or some other organization above or below in the hierarchy.

As an example, the following is the data for the Federal Administration Training Centre:

  • identifier: fatc
  • label en: Federal Administration Training Centre
  • label de: Ausbildungszentrum der Bundesverwaltung
  • label fr: Centre de formation de l'administration fédérale
  • label it: Centro di formazione dell'Amministrazione federale
  • subject: education.ld.admin.ch
  • IRI: https://ld.admin.ch/office/V.1.4

A separate registration process is needed to publish cubes also on opendata.swiss.

Visualize Grafics directly in opendata.swiss

Opendata.swiss displays resources with the prefix "visualize.admin.ch" as an iframe. This means that when a dcat:Distribution has the prefix "visualize.admin.ch" in its dct:title, the accessURL is displayed as an iFrame. See:

https://visualize.admin.ch/en/browse?previous=%7B%22includeDrafts%22%3Afalse%7D&dataset=https%3A%2F%2Fenvironment.ld.admin.ch%2Ffoen%2Fnfi%2Fnfi_C-90%2Fcube%2F2024-1&dataSource=Prod a dcat:Distribution ; dct:format http://publications.europa.eu/resource/authority/file-type/HTML ; dct:issued "2023-06-22T05:27:53+00:00"^^xsd:dateTime ; dct:license http://dcat-ap.ch/vocabulary/licenses/terms_by ; dct:rights http://dcat-ap.ch/vocabulary/licenses/terms_by ; dct:title "visualize.admin.ch"@de, "visualize.admin.ch"@en, "visualize.admin.ch"@fr, "visualize.admin.ch"@it ; dcat:accessURL https://visualize.admin.ch/en/browse?previous=%7B%22includeDrafts%22%3Afalse%7D&dataset=https%3A%2F%2Fenvironment.ld.admin.ch%2Ffoen%2Fnfi%2Fnfi_C-90%2Fcube%2F2024-1&dataSource=Prod ; dcat:mediaType http://www.iana.org/assignments/media-types/text/html

To my knowledge, this resource is automatically added when I activate the publication on opendata.swiss in LINDAS. Alternatively, I can manually create a publication in the CKAN backend and add a corresponding resource. The relevant fields are "Title" and "Access URL".

image