[英]Order of actions in creating a R package with devtools
I am currently developing a package for R.我目前正在为 R 开发 package。 I have functions (of course), datasets, vignettes and tests.
我有函数(当然)、数据集、小插曲和测试。 The vignettes are to be processed with
Rmarkdown
and the manuals with Roxygen2
, finally, the tests are to be performed with testthat
(so far everything works ok).小插图将使用
Rmarkdown
处理,手册使用Roxygen2
,最后,测试将使用testthat
执行(到目前为止一切正常)。
I would like to develop and finalize the package entirely from within R with devtools
instructions.我想使用
devtools
指令完全从 R 中开发和完成 package。 I would like to know the optimal order to call these functions.我想知道调用这些函数的最佳顺序。 At this time, I use in that order
这时候,我按那个顺序使用
devtools::document("package folder")
devtools::build("package folder")
devtools::install("package folder", upgrade = "never")
devtools::run_examples("package folder")
devtools::test("package folder")
devtools::build_vignettes("package folder")
devtools::check("package folder", cran=TRUE)
My question shows my lack of understanding of what these functions do precisely.我的问题表明我对这些功能的确切作用缺乏了解。 Hence, a brief summary of the role of each function would be appreciated.
因此,我们将不胜感激每个 function 的作用的简要总结。 Also, am I missing some steps?
另外,我错过了一些步骤吗? or are some function calls above unrequired?
还是不需要上面的一些 function 调用?
Chapter 2 ( The whole game ) of the R package explains all in detail. R package的第2章(全游戏)详细解释了所有内容。 The one that you are missing yet is beneficial is load_all(), which loads your modified functions into the memory.
您缺少但有益的是 load_all(),它将您修改的函数加载到 memory 中。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.