read_stats: Read a .json file that was produced with 'write_stats()'

View source: R/read_stats.R

read_statsR Documentation

Read a .json file that was produced with write_stats()

Description

read_stats() can read a .json file containing statistics that was produced using tidystats. It returns a list containing the statistics, with the identifier as the name for each list element.

Usage

read_stats(file)

Arguments

file

A string specifying the path to the tidystats data file.

Examples

# A simple example, assuming there is a file called 'statistics.json'
## Not run: 
statistics <- read_stats("statistics.json")

## End(Not run)

# A working example
statistics <- read_stats(
  file = system.file("statistics.json", package = "tidystats")
)


tidystats documentation built on Oct. 17, 2023, 1:06 a.m.