powered by
The JSON types are
null
true, false
integer
real
array
object
json_type(x, path = NULL)
A JSON vector
Path to element. This must be a valid JSONpath expression. For example "$.a.b[0] extracts the 1 in {"a": {"b": [1, 2]}}.
"$.a.b[0]
1
{"a": {"b": [1, 2]}}
A character vector of JSON types
# NOT RUN { json_type(c(NA, "1", "null", "[1,2]", '{"a": 1}')) # }
Run the code above in your browser using DataLab