Add citation information to package R

I am building my R package using Roxygen2 and devtools , and I would like to add some quotation to my R codes (i.e. I hope to write in a .R file from which auto-generation can be referenced). The ultimate goal is to show, as soon as I run the citation(MyPkgName) , the quotes of the R package, as well as the quote (preferably with a BibTeX record) of the paper I submit. Is there a way to do this with devtools ? Thanks!

+5
source share
2 answers

The CITATION file must be in the inst directory. See the official documentation for details on what should be in the file.

+5
source

CITATION template can be created automatically with

 usethis::use_citation() 

Once the file is created, you only need to fill in the blanks.

0
source

Source: https://habr.com/ru/post/1480296/


All Articles