| wb_document | R Documentation |
Search the World Bank Documents & Reports archive from the Documents & Reports API.
wb_document(
search = NULL,
country = NULL,
type = NULL,
project = NULL,
start_date = NULL,
end_date = NULL,
id = NULL,
limit = NULL
)
search |
( |
country |
( |
type |
( |
project |
( |
start_date |
( |
end_date |
( |
id |
( |
limit |
( |
A data.frame() with World Bank document data. Since a document can have several
types, countries, regions, and projects, type, major_type, country_code, country,
region, and project_id hold all of them separated by ;, which never occurs within a
value. Use strsplit(x, ";") to split them. The columns are:
id: The document ID.
title: The document title.
type: The document types.
major_type: The major document types.
country_code: The World Bank country codes.
country: The country names. They are not in the same order as country_code, and a code can
have more than one name, so the two can't be matched by position.
region: The administrative region names.
language: The document language.
date: The document date.
report_number: The report number.
project_id: The IDs of the associated projects, or NA if there are none.
url: The document URL.
pdf_url: The PDF URL.
abstract: The abstract.
https://search.worldbank.org/api/v3/wds
# project appraisal documents for Brazil published in 2024
wb_document(
country = "BR",
type = "Project Appraisal Document",
start_date = "2024-01-01",
end_date = "2024-12-31"
)
# all documents belonging to a project
wb_document(project = "P180429")
# the first 100 documents mentioning climate
docs <- wb_document(search = "climate", limit = 100)
# the ones covering more than one country
docs[grepl(";", docs$country_code), c("title", "country_code")]
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.