Creating an R package for your final project (locally)

1. Creating a new R package in RStudio:

  1. File -> New Project -> New Directory -> R Package
  2. Enter a good name and folder for your package. I’ll call mine portaldata
  3. Click “Create git repository”
  4. Click “Create Project” button to create your new project

2. Customize the DESCRIPTION file

3. Adding a README

4. Adding data to the package

5. Documenting the data

#' Portal Data Set and Analysis
#'
#' This package contains data sets from the Portal Project
#' for easy reuse and reanalysis.
#'
#' @docType package
#' @name portaldata
#' @aliases portaldata portaldata-package
NULL

#' Taxonomy of species sampled
#'
#' A data set containing the taxonomy of species sampled for the Portal Project Data.
#' We followed the taxonomy from the Open Tree of Life .
#'
#' @source \url{https://lunasare.github.io/spring2023-data-science/data/portal-species-taxonomy.csv}
#' @format A data frame with X number of columns and Y number of rows
"taxonomy"

6. Version control and remote repository

7. Creating a website for your R package

Activating Github Pages on a Repository

8. Customize the website

8. Adding a vignette