Title: | R Interface to the 'Deutsche Nationalbibliothek (German National Library) API' |
---|---|
Description: | A wrapper for the 'Deutsche Nationalbibliothek (German National Library) API', available at <https://www.dnb.de/EN/Home/home_node.html>. The German National Library is the German central archival library, collecting, archiving, bibliographically classifying all German and German-language publications, foreign publications about Germany, translations of German works, and the works of German-speaking emigrants published abroad between 1933 and 1945. |
Authors: | Christian Graul [aut, cre] |
Maintainer: | Christian Graul <[email protected]> |
License: | MIT + file LICENSE |
Version: | 0.1-6 |
Built: | 2024-11-18 05:54:53 UTC |
Source: | https://github.com/chgrl/rdnb |
changes
brings up the NEWS file of the package.
changes(pkg = "rdnb")
changes(pkg = "rdnb")
pkg |
Set to the default "rdnb". Other packages make no sense. |
## Not run: changes() ## End(Not run)
## Not run: changes() ## End(Not run)
dnb_search
exposes a search in the DNB catalogue, expressed in the DNB query language.
dnb_advanced(query, limit = 10, clean = TRUE, print = FALSE)
dnb_advanced(query, limit = 10, clean = TRUE, print = FALSE)
query |
the search query, expressed in the DNB query language; single string value. |
limit |
number and (optional) starting point of results returned; single integer value (number of results), vector of two integer values (number of results and first result, >=1) or |
clean |
if |
print |
if |
Cleaning of results
To harmonise the results, some clutter is deleted and abbreviations frequently used in the dnb catalogue are replaced by full words. Here is a list of all replacements:
Variable | Searched | Replaced by |
complete dataset | \u0098 | [deleted] |
complete dataset | \u009c | [deleted] |
complete dataset | ,, | , |
complete dataset | .. | . |
complete dataset | ;; | ; |
year | [string] | [numeric] |
pages | S. | [deleted] |
pages | Seiten | [deleted] |
pages | [ | [deleted] |
pages | ] | [deleted] |
publisher | Verl. | Verlag |
publisher | verl. | verlag |
publisher | [ | [deleted] |
publisher | ] | [deleted] |
edition | Aufl. | Auflage |
edition | aufl. | auflage |
edition | Orig. | Original |
edition | Ed. | Edition |
edition | ed. | edition |
edition | Ausg. | Ausgabe |
edition | ausg. | ausgabe |
edition | Nachdr. | Nachdruck |
edition | Bibliogr. | Bibliografie |
edition | [ | [deleted] |
edition | ] | [deleted] |
edition | [x]., | [x]. |
price | kart. | Kartoniert |
price | Gb. | Gebunden |
price | Spiralb. | Spiralbindung |
price | Pb. | Paperback |
A data.frame
of results with metadata.
## Not run: # german books titled with 'cat' (male or female), # excluding titles containing dogs, since the year 2001 cats <- dnb_advanced("(tit=katze OR tit=kater NOT tit=hund) AND jhr>2000 AND mat=books AND spr=ger") ## End(Not run)
## Not run: # german books titled with 'cat' (male or female), # excluding titles containing dogs, since the year 2001 cats <- dnb_advanced("(tit=katze OR tit=kater NOT tit=hund) AND jhr>2000 AND mat=books AND spr=ger") ## End(Not run)
dnb_search
exposes a search in the DNB catalogue.
dnb_search( title, author, year, publisher, keyword, type, language, limit = 10, clean = TRUE, print = FALSE )
dnb_search( title, author, year, publisher, keyword, type, language, limit = 10, clean = TRUE, print = FALSE )
title |
the title (including subtitle, short title, volume title, etc.); optional single string value or vector of strings. |
author |
the author(s); optional single string value or vector of strings. |
year |
the year of publishing; optional single integer value or vector of integers. |
publisher |
the publisher (publisher name and/or location); optional single string value or vector of strings. |
keyword |
one or a set of keywords describing the work (subjects, persons, locations, organisations, etc.); optional single string value or vector of strings. |
type |
the type of publication (optional), one or a vector of |
language |
the language of the work by ISO 639-2/B code (https://en.wikipedia.org/wiki/List_of_ISO_639-2_codes); single string value or vector of strings. |
limit |
number and (optional) starting point of results returned; single integer value (number of results), vector of two integer values (number of results and first result, >=1) or |
clean |
if |
print |
if |
to do
A list of results with metadata.
## Not run: # title search single.title <- dnb_search(title="katze") multi.title <- dnb_search(title=c("katze", "kater", "+maus", "-hund")) # author search single.author <- dnb_search(author="kern") author.or.author <- dnb_search(author=c("kern", "locke")) author.and.author <- dnb_search(author=c("kern", "+locke")) author.not.author <- dnb_search(author=c("kern", "-locke")) # publication year single.year <- dnb_search(title="katze", year=2015) sequence.of.years <- dnb_search(title="katze", year=2010:2015) set.of.years <- dnb_search(title="katze", year=c(2010:2013, 2015)) # publisher search single.publisher <- dnb_search(title="katze", publisher="kiepenheuer") set.of.publishers <- dnb_search(title="katze", publisher=c("kiepenheuer", "piper")) # keyword search single.keyword <- dnb_search(author="kern") keyword.or.keyword <- dnb_search(keyword=c("katze", "hund")) keyword.and.keyword <- dnb_search(keyword=c("katze", "+hund")) keyword.not.keyword <- dnb_search(keyword=c("katze", "-hund")) # type search single.type <- dnb_search(title="katze", type="books") set.of.types <- dnb_search(title="katze", type=c("books", "articles", "online")) # language search single.language <- dnb_search(title="cat", language="eng") set.of.languages <- dnb_search(title=c("cat", "katze"), language=c("eng", "ger")) # change limit of results first.result <- dnb_search(title="katze", limit=1) 5.results.starting.with.the.21st <- dnb_search(title="katze", limit=c(5, 21)) all.results <- dnb_search(title="katze", limit="all") ## End(Not run)
## Not run: # title search single.title <- dnb_search(title="katze") multi.title <- dnb_search(title=c("katze", "kater", "+maus", "-hund")) # author search single.author <- dnb_search(author="kern") author.or.author <- dnb_search(author=c("kern", "locke")) author.and.author <- dnb_search(author=c("kern", "+locke")) author.not.author <- dnb_search(author=c("kern", "-locke")) # publication year single.year <- dnb_search(title="katze", year=2015) sequence.of.years <- dnb_search(title="katze", year=2010:2015) set.of.years <- dnb_search(title="katze", year=c(2010:2013, 2015)) # publisher search single.publisher <- dnb_search(title="katze", publisher="kiepenheuer") set.of.publishers <- dnb_search(title="katze", publisher=c("kiepenheuer", "piper")) # keyword search single.keyword <- dnb_search(author="kern") keyword.or.keyword <- dnb_search(keyword=c("katze", "hund")) keyword.and.keyword <- dnb_search(keyword=c("katze", "+hund")) keyword.not.keyword <- dnb_search(keyword=c("katze", "-hund")) # type search single.type <- dnb_search(title="katze", type="books") set.of.types <- dnb_search(title="katze", type=c("books", "articles", "online")) # language search single.language <- dnb_search(title="cat", language="eng") set.of.languages <- dnb_search(title=c("cat", "katze"), language=c("eng", "ger")) # change limit of results first.result <- dnb_search(title="katze", limit=1) 5.results.starting.with.the.21st <- dnb_search(title="katze", limit=c(5, 21)) all.results <- dnb_search(title="katze", limit="all") ## End(Not run)
n_rec
returns the number of items in a list of records returned by a DNB-search.
n_rec(dnb_obj)
n_rec(dnb_obj)
dnb_obj |
the DNB-search object returned |
Number of records found.
## Not run: dnb.srch <- dnb_search(title="katze") n_rec(dnb.srch) ## End(Not run)
## Not run: dnb.srch <- dnb_search(title="katze") n_rec(dnb.srch) ## End(Not run)
print_query
prints out the query used for a DNB-search request.
print_query(dnb_obj)
print_query(dnb_obj)
dnb_obj |
the DNB-serch object returned by |
Query string.
## Not run: dnb.srch <- dnb_search(title="katze") print_query(dnb.srch) ## End(Not run)
## Not run: dnb.srch <- dnb_search(title="katze") print_query(dnb.srch) ## End(Not run)
A wrapper for the Deutsche Nationalbibliothek (German National Library) API, available at https://www.dnb.de/EN/Home/home_node.html. The German National Library is the German central archival library, collecting, archiving, bibliographically classifying all German and German-language publications, foreign publications about Germany, translations of German works, and the works of German-speaking emigrants published abroad between 1933 and 1945.
All bibliographic data of the German National Library are provided free of charge and can be freely re-used under "Creative Commons Zero" (CC0 1.0) terms. The metadata and online interfaces are provided with no guarantee of their being continuous, punctual, error-free or complete, or of their not infringing the rights of third parties (e.g. personal rights and copyright).
About the DNB: https://www.dnb.de/EN/Ueber-uns/ueberUns_node.html; about the interface: https://www.dnb.de/EN/Professionell/Metadatendienste/Datenbezug/SRU/sru_node.html