summary.openEBGM {openEBGM}R Documentation

Summarize an openEBGM object

Description

Summarize an openEBGM object

Usage

## S3 method for class 'openEBGM'
summary(object, plot.out = TRUE, log.trans = FALSE, ...)

Arguments

object

An openEBGM object constructed by ebScores

plot.out

A logical value indicating whether or not a histogram of the EBGM scores should be displayed

log.trans

A logical value indicating whether or not the data should be log-transformed.

...

Additional arguments affecting the summary produced

Details

This function provides a brief summary of the results of the calculations performed in the ebScores function. In particular, it provides the numerical summary of the EBGM and QUANT_* vectors.

Additionally, calling summary on an openEBGM object will produce a histogram of the EBGM scores. By setting the log.trans parameter to TRUE, one can convert the EBGM score to EBlog2, which is a Bayesian version of the information criterion (DuMouchel).

References

DuMouchel W (1999). "Bayesian Data Mining in Large Frequency Tables, With an Application to the FDA Spontaneous Reporting System." The American Statistician, 53(3), 177-190.

Examples

data.table::setDTthreads(2)  #only needed for CRAN checks
theta_init <- data.frame(
  alpha1 = c(0.5, 1),
  beta1  = c(0.5, 1),
  alpha2 = c(2,   3),
  beta2  = c(2,   3),
  p      = c(0.1, 0.2)
)
data(caers)
proc <- processRaw(caers)
squashed <- squashData(proc, bin_size = 300, keep_pts = 10)
squashed <- squashData(squashed, count = 2, bin_size = 13, keep_pts = 10)
suppressWarnings(
  hypers <- autoHyper(data = squashed, theta_init = theta_init)
)
ebout <- ebScores(processed = proc, hyper_estimate = hypers, quantiles = 5)
summary(ebout)
## Not run: summary(ebout, plot.out = FALSE)
## Not run: summary(ebout, log.trans = TRUE)


[Package openEBGM version 0.9.1 Index]