Skip to content
Creates Folders For R Project
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
R
inst/figures
man
vignettes
.Rbuildignore
.gitignore
DESCRIPTION
NAMESPACE
README.Rmd
README.md
organiser.Rproj

README.md

organiser

Lifecycle: experimental

sticker

The goal of organiser is to use a single file structure convention for R project

Installation

You can install the released version of organiser from Github with:

# install.packages("remotes")
remotes::install_github("AbderrahmenDHIF/organiser")

File structure

The function add_file creates 4 folders and a Readme file described above:

  • Data_src: Raw source data
  • Script: All R scripts
  • Data_save: Intermediate data objects. Typically, I save these as RDS files (with saveRDS and readRDS)
  • Output: The final output. Typically, is a html file generated by Rmarkdown
  • README.Rmd: Describes the project

file

Script structure

The Scriptfolder contains 3 R scripts described above:

  • R_00_global_script: Fixing paramters, loading libraries and sourcing scripts
  • R_01_Data_management: Preparing data for analysis (e.g. cleaning data, creating features ...)
  • R_02_Data_analysis: Transforming data into information (e.g. aggregation, tidying ...)

script

Example

Create an R project first, then you can use the exemple above

library(organiser)
## create the file and the script structure described below
add_file()
## create an additional script inside the script folder
add_script("name_of_script")
You can’t perform that action at this time.