objectToString: Object to string

View source: R/soundgen_utilities.R

objectToStringR Documentation

Object to string

Description

Internal soundgen function. Converts any object to a string that preserves all internal structure and names.

Usage

objectToString(x)

Arguments

x

any R object (unquoted)

Examples

soundgen:::objectToString('adja')
soundgen:::objectToString(500)
soundgen:::objectToString(c(870, 1250, 1900))
soundgen:::objectToString(list(f1 = c(870, 1250), f2 = list(freq = 500, amp = 30)))
soundgen:::objectToString(list(
  pitch = list(time = c(0, 1), value = c(160, 150)),
  noise = list(time = c(-1, 170, 362), value = c(-14, 0, -26)),
  mouth = list(time = c(0, 0.07, 1), value = c(0, 0.48, 0.32))))
# NB: no matter how long, the object is still returned as an unbroken string

soundgen documentation built on Sept. 12, 2024, 6:29 a.m.