Learn R Programming

supreme (version 1.1.0)

src_yaml: Read a YAML file containing a model

Description

Reads an object or a file in YAML format and returns a model YAML object.

Usage

src_yaml(file = NULL, text = NULL)

Arguments

file

file path to a YAML file.

text

a YAML formatted character string.

Value

A src_yaml object.

See Also

Other source functions: src_file()

Examples

Run this code
# NOT RUN {
## Read from a file:
path <- example_yaml()
src_yaml(path)

## Read from an (text) object:
model <- "
- name: childModuleA
  input: [input.data, reactive]
  src: package

- name: childModuleB
  input: selected.model
"
src_yaml(text = model)
# }

Run the code above in your browser using DataLab