我可以在一个引文文件中同时添加 R 包的两个引用(一个包,一个文章)吗?

Can I add two citations for R package (One for package, one for article) at the same time in one citation file?

在我使用 sethis::use_citation() 为 R 包创建引用文件后。

显示模板如下

citHeader("To cite package_name in publications use:")

citEntry(
  entry    = "Article",
  title    = ,
  author   = ,
  journal  = ,
  year     = ,
  volume   = ,
  number   = ,
  pages    = ,
  url      = ,
  textVersion = paste(

  )
)

但是,我想引用 包本身 包相关文章 ,我应该为 [= 创建另一个类似的模板吗? 22=]包本身 跟随?如

citHeader("To cite package_name in publications use:")

citEntry(
  entry    = "Article",
  title    = ,
  author   = ,
  journal  = ,
  year     = ,
  volume   = ,
  number   = ,
  pages    = ,
  url      = ,
  textVersion = paste(

  )
)

citEntry(
  entry    = "Manual",
  title    = ,
  author   = ,
  journal  = ,
  year     = ,
  volume   = ,
  number   = ,
  pages    = ,
  url      = ,
  textVersion = paste(

  )
)

另外,其实我还有另一种格式,但不是这个R自动创建的模板。任何人都知道我是否可以使用它

@Manual{package_name,
    title = {{package_name}: },
    author = {},
    year = {},
    note = {},
    url = {},
  } 
  @Article{,
  author  = {},
  journal = {},
  title   = {{package_name}: },
  year    = {},
  volume  = {},
  number  = {}
}

当然可以。有很多先例。例如 CITATION file for out Rcpp 包中有两篇文章和一本书。

您可以在您的系统上执行类似的操作来查找您已安装的十个最大的文件:

edd@rob:~$ ls -Srl /usr/local/lib/R/site-library/*/CITATION | tail -10
-rw-rw-r-- 1 1000 50 2562 Apr 26 17:50 /usr/local/lib/R/site-library/spam/CITATION
-rw-rw-r-- 1 1000 50 2614 Apr 26 17:55 /usr/local/lib/R/site-library/strucchange/CITATION
-rw-rw-r-- 1 1000 50 2653 Apr 26 17:56 /usr/local/lib/R/site-library/RProtoBuf/CITATION
-rw-rw-r-- 1 1000 50 2878 Apr 26 17:45 /usr/local/lib/R/site-library/stabs/CITATION
-rw-rw-r-- 1 1000 50 2900 Apr 26 17:44 /usr/local/lib/R/site-library/colorspace/CITATION
-rw-rw-r-- 1 1000 50 3471 Apr 26 17:45 /usr/local/lib/R/site-library/statmod/CITATION
-rw-rw-r-- 1 1000 50 3957 Jun 16 08:32 /usr/local/lib/R/site-library/party/CITATION
-rw-rw-r-- 1 1000 50 4352 Aug  6 10:36 /usr/local/lib/R/site-library/mboost/CITATION
-rwxrwxr-x 1 1000 50 4367 Apr 26 17:44 /usr/local/lib/R/site-library/DEoptim/CITATION
-rw-rw-r-- 1 1000 50 4835 Apr 30 21:56 /usr/local/lib/R/site-library/VGAM/CITATION
edd@rob:~$