-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
6889f01
commit cc2fa97
Showing
1 changed file
with
23 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,23 @@ | ||
#' @title JSON summary | ||
#' | ||
#' @description | ||
#' produces a json summary of includes dataset specified by parameter [d]. | ||
#' @param d | ||
#' A \code{string} representing the dataset name which json representation should be returned. | ||
#' @return | ||
#' returns a json representation of an included dataset | ||
#' @author | ||
#' @export | ||
#' @examples | ||
|
||
jsonSummary <- function(d) { | ||
requireNamespace("jsonlite") | ||
|
||
#load the in variable d defined dataset from the package | ||
dat <- checkData(d) | ||
|
||
val <-jsonlite::toJSON(lapply(dat, function(x){as.list(summary(x))}), pretty = TRUE, auto_unbox = TRUE) | ||
return(val) | ||
|
||
} | ||
|
||
#' @title JSON summary | ||
#' | ||
#' @description | ||
#' produces a json summary of includes dataset specified by parameter [d]. | ||
#' @param d | ||
#' A \code{string} representing the dataset name which json representation should be returned. | ||
#' @return | ||
#' returns a json representation of an included dataset | ||
#' @author | ||
#' @export | ||
#' @examples | ||
|
||
jsonSummary <- function(d) { | ||
requireNamespace("jsonlite") | ||
|
||
#load the in variable d defined dataset from the package | ||
dat <- checkData(d) | ||
|
||
val <-jsonlite::toJSON(lapply(dat, function(x){as.list(summary(x))}), pretty = TRUE, auto_unbox = TRUE) | ||
return(val) | ||
|
||
} | ||
|