Get item definitions by QID from a Wikibase instance or Wikidata.
Usage
get_item(
qid,
language,
prefix = "http://www.wikidata.org/entity/",
wikibase_api_url = "https://www.wikidata.org/w/api.php",
creator = person("Jane", "Doe"),
title = "Dataset title"
)Arguments
- qid
A single QID or a vector of QIDs on a Wikibase instance (or Wikidata itself.)
- language
A character vector of language codes, for example,
c("en", "nl", "hu").- prefix
The prefix to use before the QID, for example, defaults to
"http://www.wikidata.org/entity/".- wikibase_api_url
Defaults to
"https://www.wikidata.org/w/api.php".- creator
The creator (author) of the dataset.
- title
The title of the dataset.
Value
A dataset with the QIDs, labels, description, and the language codes of the labels and descriptions.
Examples
get_item("Q42", language = c("en", "nl"))
#> Downloaded Q42
#> Doe J (????). "Dataset title."
#> rowid qid label description language
#> <hvn_lbl_> <hvn_lbl_> <hvn_lbl_> <hvn_lbl_> <hvn_lb>
#> 1 eg:1 Q42 Douglas Adams English science fiction writer a… en
#> 2 eg:2 Q42 Douglas Adams Engelse schrijver (1952-2001) nl