| cite_capsule | R Documentation |
Builds a ready-to-paste data citation (plain text and BibTeX
@misc) from a provenance object's dataset and resource blocks,
using publisher, resource name, source system, retrieval date,
license, the pinned URL, and a DOI when one is recorded
(dataset$doi).
cite_capsule(provenance)
provenance |
A provenance list as returned by
|
A list with text and bibtex character scalars, or NULL
if provenance is NULL.
prov <- list(
captured_at_utc = "2026-06-23T04:41:40Z",
dataset = list(publisher = "Ontario Ministry of the Solicitor General",
licence_short = "OGL-Ontario",
package_slug = "data-on-inmates-in-ontario"),
resource = list(name = "Restrictive Confinement - Detailed Dataset",
direct_url = "https://data.ontario.ca/example.csv")
)
cit <- cite_capsule(prov)
# Plain-text citation ready to paste.
cat(cit$text)
# BibTeX @misc entry for LaTeX bibliographies.
cat(cit$bibtex)
# NULL provenance returns NULL (composes safely).
cite_capsule(NULL)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.