Learn R Programming

ProjectTemplate (version 0.11.0)

Automates the Creation of New Statistical Analysis Projects

Description

Provides functions to automatically build a directory structure for a new R project. Using this structure, 'ProjectTemplate' automates data loading, preprocessing, library importing and unit testing.

Copy Link

Version

Install

install.packages('ProjectTemplate')

Monthly Downloads

985

Version

0.11.0

License

GPL-3 | file LICENSE

Maintainer

Last Published

July 1st, 2024

Functions in ProjectTemplate (0.11.0)

.cache.format

Get configured cache file format strategy
.is.ProjectTemplate

Test whether a given path is a ProjectTemplate project
.attach.or.add.namespace

Attach a package or add a namespace
.create.project.existing

Create a project structure
.dir.empty

Check if a directory is empty
.get.template

Get the location of a template from its name
.is.cache.empty

Check whether the cache is empty
.stopifnotproject

Raise an error if given path is not a valid project
.evaluate.code

Run code and assign the results to variable
.load.helpers

Load the helper functions
.rstudioprojectfile

Return an RStudio project file as character vector
migrate.template

Migrate a template to a new version of ProjectTemplate
.cache.filename

Construct the file names for the cache and hash
.convert.to.tibble

Convert one or more data sets to tibbles
.has.project

Check if the project was loaded
.remove.sticky.vars

Remove variables to keep from a list of candidates for removal
.load.data

Load the data from the cache and data directories
.is.cached

Check whether variables are cached
.list.data

Build the list of data available for loading into memory
.require.package

Require internal package
.create.cache.hash

Create a data.frame with the cache metadata
.load.libraries

Load the libraries listed in the configuration into memory
.init.logger

Initialize the logger for the project
project.config

ProjectTemplate Configuration file
.is.dir

Check if path is an existing directory
loadproject_addin

Load Project
preinstalled.readers

Automatically read data into memory
migrate.project

Migrates a project from a previous version of ProjectTemplate
stub.tests

Generate unit tests for your helper functions.
reload.project

Reload or reset a project
test.project

Run all unit tests for this project.
translate.dcf

Read a DCF file into an R list.
.write.cache

Write a variable and its metadata to cache
list.data

Listing the data for the current project
run.project

Run all of the analyses in the src directory.
load.project

Automatically load data and packages for a project.
.read.cache.info

Read metadata for a variable in the cache
.prepare.data.ignore.regex

Prepare a regular expression for matching files to be ignored
.provide.directory

Make sure a required directory exists before usage
require.package

Require a package for use in the project
show.project

Show information about the current project.
.list.files.and.dirs

List all files and directories, excluding .. and .
.package.version

Get the current ProjectTemplate version
.var.diff.from

Compare sets of variable names
reloadproject_addin

Reload Project
.munge.data

Source all munge scripts
.quietstop

Stop silently
.parse.extensions

Match readers to the extensions of the data files
.stopifproject

Raise an error if given path is a valid project
.unload.project

Unload the project variables keeping the data
ProjectTemplate-package

ProjectTemplate: Automates the Creation of New Statistical Analysis Projects
cache

Cache a data set for faster loading.
create.project

Create a new project.
clear

Clear objects from the global environment
.add.extension

Associate a reader function with an extension.
clear.cache

Clear data sets from the cache
add.config

Add project specific config to the global config
cache.project

Cache a project's data sets in binary format.
get.project

Show information about the current project.
create.template

Create a new template
cache.name

Translate a variable name into a file name for caching.
clean.variable.name

Translate a file name into a valid R variable name.
.check.version

Compare the project version with the current ProjectTemplate version
.cached.variables

List all cached variables
.cache.hash

Calculate the hash of the data stored in a variable
.cache.status

Print the current cache status
.convert.to.data.table

Convert one or more data sets to data.tables