Learn R Programming

TAF (version 4.3.0)

TAF-package: Transparent Assessment Framework for Reproducible Research

Description

General framework to organize data, methods, and results used in reproducible scientific analyses. A TAF analysis consists of four scripts (data.R, model.R, output.R, report.R) that are run sequentially. Each script starts by reading files from a previous step and ends with writing out files for the next step.

Convenience functions are provided to version control the required data and software, run analyses, clean residues from previous runs, manage files, manipulate tables, and produce figures. With a focus on stability and reproducible analyses, the TAF package comes with no dependencies. TAF forms a base layer for the icesTAF package and other scientific applications.

The following diagram describes the general workflow of every TAF analysis:

diagram

See vignette("TAF") for more detailed coverage on how to organize and run TAF workflows.

Arguments

Author

Arni Magnusson, Colin Millar, and Iago Mosqueira.

Details

Initial TAF steps:

draft.datadraft DATA.bib file
draft.softwaredraft SOFTWARE.bib file
periodpaste period string for DATA.bib
taf.bootset up data files and software
taf.examplecopy example analysis from TAF package
taf.skeletoncreate empty TAF template

Running scripts:

cleanclean TAF directories
clean.bootclean boot directory
makerun R script if needed
make.allrun all TAF scripts as needed
make.tafrun TAF script if needed
msgshow message
source.allrun all TAF scripts
source.tafrun TAF script

File management:

convert.spacesconvert spaces
cpcopy files
mkdircreate directory
os.linuxoperating system
os.macosoperating system
os.windowsoperating system
read.tafread CSV file
source.dirsource all *.R files
taf.libraryload package from TAF library
taf.unzipunzip file
write.tafwrite CSV file

Tables:

ddimshow data dimensions
divdivide column values
flr2tafconvert FLR to TAF
long2tafconvert long format to TAF
long2xtabconvert long format to crosstab
plusrename plus group column
rndround column values
sam2tafconvert SAM to TAF
taf2htmlconvert data frame to HTML
taf2longconvert TAF to long format
taf2xtabconvert TAF to crosstab
tttranspose TAF table
wide2longconvert wide to long format
xtab2longconvert crosstab to long format
xtab2tafconvert crosstab to TAF

Plots:

limcompute axis limits
taf.colorspredefined colors
taf.pngopen PNG graphics device
zoomchange lattice text size

Example tables:

catage.longlong format
catage.tafTAF format
catage.widewide format
catage.xtabcrosstab format
summary.tafsummary results

Example workflow:

linregsimple linear regression

Administrative or auxiliary tools:

check.softwarecheck global package versions
clean.dataclean boot data
clean.libraryclean TAF library
clean.softwareclean TAF software
depsworkflow dependencies
detach.packagesdetach all packages
dir.treeshow directory structure
dos2unixconvert line endings
downloaddownload file
download.githubdownload repository
draft.readmedraft introductory readme
file.encodingexamine file encoding
get.remote.shalook up SHA code
git.reporead Git repository name
install.depsinstall dependencies
is.r.packagecheck if file is an R package
latin1.to.utf8convert file encoding
line.endingsexamine line endings
pdepspackage dependencies
read.bibread metadata entries
rmdirremove empty directory
taf.boot.pathconstruct path to boot folder
taf.data.pathconstruct path to boot data files
taf.installinstall package in TAF library
taf.libPathsadd TAF library to search path
taf.librariesload all packages from TAF library
taf.sessionshow session information
taf.sourceslist metadata entries
unix2dosconvert line endings
utf8.to.latin1convert file encoding

See Also

See vignette("TAF") for an introduction to the TAF package.

The TAF Wiki provides additional help resources.

Examples

Run this code
if (FALSE) {
taf.example("linreg")
setwd("linreg")
taf.boot()
source.all()
}

Run the code above in your browser using DataLab