I. Creating R packages
How to Create Your Own Package in RStudio
II. Creating R Data packages
Creating R data packages for teaching
Creating a package for your data set
How to Create an R Data Package
Creating and Using Data Packages in R
III. Example
1. install.packages("testthat")
2. open ‘New Project’ in the ‘File’ menu
3. select ‘New Directory'
4. select ‘R Package’ to create a new R package.
5. type the name of your package. and click 'Create Project' at the bottom
6. select ‘Install and Restart’ in the ‘Build’ menu
7. example : my package name is 'y1'
library(y1)
hello()
8. Distributing Packages Publicly
R packages can be distributed in a variety of ways:
Contributing packages to CRAN
Publishing on R-Forge or GitLab or Bitbucket or GitHub or Azure DevOps ...
References