File: read_json.Rd

package info (click to toggle)
r-cran-jsonlite 1.6%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 1,304 kB
  • sloc: ansic: 3,789; sh: 9; makefile: 2
file content (40 lines) | stat: -rw-r--r-- 980 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/read_json.R
\name{read_json}
\alias{read_json}
\alias{parse_json}
\alias{write_json}
\title{Read/write JSON}
\usage{
read_json(path, simplifyVector = FALSE, ...)

parse_json(json, simplifyVector = FALSE, ...)

write_json(x, path, ...)
}
\arguments{
\item{path}{file on disk}

\item{simplifyVector}{simplifies nested lists into vectors and data frames. See \link{fromJSON}.}

\item{...}{additional conversion arguments, see also \link{toJSON} or \link{fromJSON}}

\item{json}{string with literal json or connection object to read from}

\item{x}{an object to be serialized to JSON}
}
\description{
These functions are similar to \link{toJSON} and \link{fromJSON} except they
explicitliy distinguish between path and literal input, and do not simplify
by default.
}
\examples{
tmp <- tempfile()
write_json(iris, tmp)

# Nested lists
read_json(tmp)

# A data frame
read_json(tmp, simplifyVector = TRUE)
}