| cff_parse_citation {cffr} | R Documentation |
bibentry to cffParse a bibentry object to a valid format for a CITATION.cff file.
cff_parse_citation(bib)
bib |
A |
This is a helper function designed to help on adding or replacing the auto-generated authors of the package. See Examples.
This function tries to adapt a bibentry object (generated with bibentry()
or citEntry()) to the CFF standard.
Article, Book, Booklet, InBook, InCollection,
InProceedings, Manual, MastersThesis, Misc, PhDThesis,
Proceedings, TechReport, Unpublished. See bibentry()
for more information.
Note that Conference is not implemented in
bibentry(), however is equivalent to InProceedings (Patashnik (1988)).
address, author, booktitle, chapter, edition, editor, howpublished, institution, journal, key, month, note, number, organization, pages, publisher, school, series, title, type, year.
annote and crossref fields are ignored.
A cff object ready to be used on cff_create().
Patashnik, Oren. "BIBTEXTING" February 1988. https://osl.ugr.es/CTAN/biblio/bibtex/base/btxdoc.pdf.
Haines, R., & The Ruby Citation File Format Developers. (2021). Ruby CFF Library (Version 0.9.0) (Computer software). doi: 10.5281/zenodo.1184077.
cff_create(), vignette("cffr", "cffr"), bibentry()
Other parsers:
cff_parse_person()
bib <- citation("base")
bib
# To cff
bib_to_cff <- cff_parse_citation(bib)
bib_to_cff
# Create the object
new_cff <- cff()
full <- cff_create(new_cff, keys = list("preferred-citation" = bib_to_cff))
full
# Validate
cff_validate(full)
# Several citations
cff_parse_citation(citation("rmarkdown"))