Skip to content

Commit 796d60c

Browse files
committed
add some ppd stat examples
1 parent efaeb89 commit 796d60c

File tree

4 files changed

+20
-0
lines changed

4 files changed

+20
-0
lines changed

R/ppc-test-statistics.R

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,7 @@
8888
#' color_scheme_set("brewer-Paired")
8989
#' ppc_stat_2d(y, yrep, stat = c("median", "mad"))
9090
#'
91+
#' # reset aesthetics
9192
#' color_scheme_set()
9293
#' bayesplot_theme_set()
9394
#'

R/ppd-test-statistics.R

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,15 @@
1818
#' @template return-ggplot-or-data
1919
#'
2020
#' @template reference-vis-paper
21+
#' @examples
22+
#' yrep <- example_yrep_draws()
23+
#' ppd_stat(yrep)
24+
#' ppd_stat(yrep, stat = "sd") + legend_none()
2125
#'
26+
#' # use your own function for the 'stat' argument
27+
#' color_scheme_set("brightblue")
28+
#' q25 <- function(y) quantile(y, 0.25)
29+
#' ppd_stat(yrep, stat = "q25") # legend includes function name
2230
NULL
2331

2432
#' @rdname PPD-test-statistics

man/PPC-test-statistics.Rd

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

man/PPD-test-statistics.Rd

Lines changed: 10 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)