src_yaml: Read a YAML file containing a model

View source: R/src-methods.R

src_yamlR Documentation

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

## 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)

strboul/supreme documentation built on Jan. 11, 2024, 12:47 a.m.