Learn R Programming

⚠️There's a newer version (0.5.0) of this package.Take me there.

pepr is not yet released, but has been submitted to CRAN and should be available for a standard installation shortly. Complete documentation and API for the pepr R package is at code.databio.org/pepr.

The pepr package: Portable Encapsulated Projects in R

pepr is an R package for reading Portable Encapsulated Projects, or PEPs, in R. If you describe your project (configuration and samples) according to this format, you can load all project metadata into R using the pepr package. To test pepr, you can try loading one of the example PEPs.

Quick start:

Install from GitHub:

devtools::install_github("pepkit/pepr")

Load a project and explore metadata like this:

library("pepr"")
cfgPath = system.file(
    "extdata",
    paste0("example_peps-master"),
    "example_basic",
    "project_config.yaml",
    package = "pepr"
  )
p = Project(file = cfgPath)

sampleTable(p)
config(p)

Copy Link

Version

Install

install.packages('pepr')

Monthly Downloads

223

Version

0.3.2

License

BSD_2_clause + file LICENSE

Maintainer

Michal Stolarczyk

Last Published

June 4th, 2020

Functions in pepr (0.3.2)

.inferProjectName

Infer project name
.matchesAndRegexes

Create a list of matched files in the system and unmatched regular expessions
.mergeAttrs

Merge samples defined in sample table with ones in subsample table
.expandList

Recursively try to expand list of strings
.expandPath

Expand system path
.deriveAttrs

Derive attributes
.reformat

Check config spec version and reformat if needed
.removeAttrs

Remove attributes across all the samples
.duplicateAttrs

Duplicate a selected attribute across all the samples
.strformat

Format a string like python's format method
.isAbsolute

Determine whether a path is absolute.
.getSubscript

Get list subscript
fetchSamples

Collect samples fulfilling the specified requirements
.checkSection

Check for a section existence in a nested list
getSample

Extract samples
.printNestedList

Print a nested list
.listifyDF

Listify data frame columns
.loadConfig

Load the config of a PEP
select-config

Access "'>Config" object elements
.modifySamples

Perform all the sample addribute modifications
getSubsample

Extract samples
makeSectionsAbsolute

Make selected sections absolute using config path
listAmendments

List amendments
.implyAttrs

Imply attributes
sampleTable

.makeAbsPath

Create an absolute path from a primary target and a parent candidate.
.loadSampleAnnotation

Read sample annotation from disk
pepr

pepr
Project-class

Portable Encapsulated Project object
Config-class

Config objects and specialized list obejcts and expand string attributes
.applyAmendments

Apply amendments
.appendAttrs

Append constant attributes across all the samples
.applyImports

Function for recursive config data imports
activateAmendments

Project

The constructor of a class representing a Portable Encapsulated Project
config

Extract "'>Project"
checkSection

Check for existence of a section in the Project config