extractRcode: extractRcode pulls out the r-code blocks from Rmd files

View source: R/rutils.R

extractRcodeR Documentation

extractRcode pulls out the r-code blocks from Rmd files

Description

extractRcode pulls out the r-code blocks from Rmd files and saves them into a separate R file.

Usage

extractRcode(indir, rmdfile, filename = "out.R")

Arguments

indir

the directory in which the rmd file is to be found and into which the output file will be placed.

rmdfile

the name of the Rmd file whose R code is to be extracted

filename

the name of the R file into which the r-code is to go.

Value

generates an R file in the working directory, otherwise returns nothing

Examples

print("wait on a real example")

haddonm/codeutils documentation built on April 15, 2024, 1:02 p.m.