Learn R Programming

exams.forge (version 1.0.10)

template: Template

Description

A text template where R code can be embedded.

Usage

template(tmpl, ...)

Value

A character where the R code is replaced by its evaluation.

Arguments

tmpl

character: template

...

named parameter used in the template

Examples

Run this code
tmpl <- "`r a`+`r b`"
template(tmpl, a=1, b=2)

Run the code above in your browser using DataLab