| json_safely | R Documentation |
Converts an R object to a valid JSON string. Returns "{}" on failure
or for NULL/empty inputs.
json_safely(x)
x |
An R object to serialize. |
A single character string containing valid JSON.
json_safely(list(a = 1, b = "hello"))
json_safely(NULL)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.