bcgov / bcdata

An R package for searching & retrieving data from the B.C. Data Catalogue
https://bcgov.github.io/bcdata
Apache License 2.0
81 stars 12 forks source link

Cite #289

Closed boshek closed 2 years ago

boshek commented 2 years ago

Addresses #273

Before I flesh out the documentation and tests I wanted to check in on behaviour. Here is the current implementation:

R> dip <- bcdc_get_data_citation("metadata-for-home-and-community-care")
Authorizing with your stored API key
R> print(dip, style = "citation")

Data Management and Stewardship Branch (2021). _Metadata for Home and Community Care_.
Data Innovation Program. Access Only, <URL:
https://catalogue.data.gov.bc.ca/dataset/2e099671-2e3a-4c17-aaf0-eb1d6e2d97d4>.

A BibTeX entry for LaTeX users is

  @Manual{,
    title = {Metadata for Home and Community Care},
    author = {{Data Management and Stewardship Branch}},
    organization = {Data Innovation Program},
    year = {2021},
    url = {https://catalogue.data.gov.bc.ca/dataset/2e099671-2e3a-4c17-aaf0-eb1d6e2d97d4},
    note = {Access Only},
  }

R> airport <- bcdc_get_data_citation("bc-airports")
Authorizing with your stored API key
R> print(airport, style = "citation")

GeoBC (2021). _BC Airports_. Joy Sinnett Nancy Liesch. Open Government Licence -
British Columbia, <URL:
https://catalogue.data.gov.bc.ca/dataset/76b1b7a3-2112-4444-857a-afccf7b20da8>.

A BibTeX entry for LaTeX users is

  @Manual{,
    title = {BC Airports},
    author = {{GeoBC}},
    organization = {Joy Sinnett},
    organization = {Nancy Liesch},
    year = {2021},
    url = {https://catalogue.data.gov.bc.ca/dataset/76b1b7a3-2112-4444-857a-afccf7b20da8},
    note = {Open Government Licence - British Columbia},
  }

Tempted to create a print method that defaults to style = "citation"

boshek commented 2 years ago

As per @stephhazlitt's comment, likely need some shim to always insert the "Province of BC" in a citation.

boshek commented 2 years ago

/document

boshek commented 2 years ago

/document