Nothing
library(testthat)
# Describe your package fusen::fill_description( pkg = here::here(), fields = list( Title = "Learn how to build A Package From Rmarkdown file", Description = "A Set of tools to understand packages structure. Use Rmarkdown First method to build a package from a defined template. Start your package with documentation. Everything can be set from a Rmarkdown file in your project.", `Authors@R` = c( person("John", "Doe", email = "john@email.me", role = c("aut", "cre"), comment = c(ORCID = "0000-0000-0000-0000")) ) ) ) # Define License with use_*_license() usethis::use_mit_license("John Doe")
This is the first tool of our wonderful package.
You can add 1
to any value
using function add_one()
.
#' Add one to any value #' #' @param value A numeric value #' #' @return Numeric. value + 1 #' @export add_one <- function(value) { result <- value + 1 return(result) }
add_one(12) add_one(56)
test_that("add_one works", { expect_equal(add_one(12), 13) expect_equal(add_one(56), 57) })
That's it ! This the end of the documented story of our package. All components are there.
# Execute in the console directly fusen::inflate(flat_file = "dev/flat_template.Rmd")
Any scripts or data that you put into this service are public.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.