Wikidata:Dataset Imports/Libris Library Database

You may find these related resources helpful:


Guidelines for using this page edit

Documenting the import edit

  • Guidelines on how to import a dataset into Wikidata are available at Wikidata:Data Import Guide.
  • Please include notes on all steps of the process.
  • Once a dataset has been imported into Wikidata please edit the page to change the progress status from in progress to complete.
  • It is strongly recommended to use Visual Editor when making changes to this page, particularly for editing any of the tables.

Creating a Wikidata item for the dataset edit

  • Please create a Wikidata item for the dataset, this will allow us to improve the coverage of datasets on Wikidata and understand what datasets are available on that topic and which of them have been added to Wikidata.
  • If you are working with very large dataset you can break it into smaller Mix n' Match catalogues, but only create one Wikidata item.
  • Link the dataset Wikidata item to this page using Wikidata Dataset Imports URL (P5195)

Getting help edit

  • If your dataset import runs into issues please edit the page to change the progress status from in progress to help needed.
  • You can ask for help on Wikidata:Project chat.

Overview edit

Dataset name edit

Libris Library Database

Source edit

National Library of Sweden

Link edit

https://biblioteksdatabasen.libris.kb.se/exportinfo/

Dataset description edit

Database of libraries (public, school, etc) in Sweden.

Additional information edit

Progress of import edit

The table below is used to track the progress of importing this dataset. The suggested column headings are most applicable to data being imported from a spreadsheet - you can change some column headings or add new columns as required to best describe the progress of this import.

Wikidata item for the datasetImport data into spreadsheetFormat the spreadsheet to import the dataStructure of data within WikidataMatch the dataset to WikidataImporting data into WikidataVisualisationsMaintainance queries and expected results
Libris library database (Q55502519)yesyesyesyes

Edit history edit

Use the table below to list batches of edits that have been completed for this dataset. Ideally each entry should have all applicable columns filled out, but at a minimum please make to add a date and description to give an idea of what was added to Wikidata and when.

DateDescriptionMethodPropertiesQualifiersReferencesStatements addedStatements removedLink to import sheet
2019-02-18Create items for ~1000 public librariesOpenRefine (direct upload)
2019-02-18Create items for ~900 school librariesOpenRefine (direct upload)
2019-02-18Create items for ~190 academic librariesOpenRefine (direct upload)

Discussion of import edit

These headings are generally useful, please change this section to suit your needs.

Wikidata item for dataset edit

Import data into spreadsheet edit

We downloaded the data in spreadsheet format from the link provided at https://biblioteksdatabasen.libris.kb.se/exportinfo/.

Format the spreadsheet to import the data edit

We used OpenRefine to view and edit the data, thus no extra formatting was necessary.

Structure of data within Wikidata edit

Field nameWikidata propertyNotes
BibliotekLabel in Swedish
Alternativt biblioteksnamnAlias in Swedish
SigelUsed to create reference URL (P854) in sources, i.e. 8fit → https://biblioteksdatabasen.libris.kb.se/library/8fit/
Bibliotekstypinstance of (P31)
Ortlocation (P276)
Latitudpart of coordinate location (P625)
Longitudpart of coordinate location (P625)
Kommunkodlocated in the administrative territorial entity (P131)This field contains the Swedish municipality code (P525)
country (P17)Not present in source data – set to Sweden (Q34) if a Swedish municipality was matched.

Match the dataset to Wikidata edit

The matching and reconciling was done in OpenRefine.

Before we started working with the dataset, there were only ca. 90 items for libraries (of any type) on Wikidata.

We decided to not touch those and instead focus on creating new items for the remaining thousands.

Because of problems with data quality, we removed some of the columns from the source data:

  • Website – examining a sample showed these were often inaccurate, i.e. by pointing at a dead page, or an irrelevant one, such as the main page of the municipality rather than the library's page.
  • Phone/e-mail – we knew from our communication with the data provider that the database was not well maintained, thus the risk of this data being outdated was higher than the possible benefit of including it.
  • Gatuadress/Postnummer/Geocode – we decided to omit address data at this stage, again because of the known problems with updating the database. Also it is not clear which of these fields were most appropriate to include. However, we will discuss this with the data provider and hopefully will be able to include some sort of address data in a later run.

In order to set the located in the administrative territorial entity (P131) property, we used the kommunkod column, which contains the Swedish municipality code (P525) of the municipality.

A bunch of entries did not have a municipality code, or had an incorrect one.

If a Swedish municipality was matched succesfully, country (P17)Sweden (Q34) was added. No country was added to entries without a matched municipality.

The database also included a bunch of libraries outside Sweden (mostly in Norway, Denmark), because they're connected to the Libris system. Those were excluded.

Importing data into Wikidata edit

The import was done using OpenRefine and its upload functionality.

We uploaded one library type at a time.

Import completion notes edit

The following batches have been ran so far edit

  1. Create school libraries
  2. Create public libraries 1 2
  3. Create academic libraries

Visualisations edit

Maintenance edit

Queries and expected results edit

Query linkDescriptionExpected results
Libraries in Sweden without municipalityInstance of subclass of library without located in the administrative territorial entity (P131)Should be edited down to zero
Libraries in Sweden without locationInstance of subclass of library without location (P276)Should be edited down to zero
Libraries in Sweden without coordsInstance of subclass of library without coordinate location (P625)Should be edited down to zero

Schedule of new data released edit