evaluation {jfa}R Documentation

Evaluate a Statistical Audit Sample

Description

evaluation() is used to perform statistical inference about the misstatement in an audit population. It allows specification of statistical requirements for the sample with respect to the performance materiality or the precision. evaluation() returns an object of class jfaEvaluation which can be used with associated summary() and plot() methods.

For more details on how to use this function, see the package vignette: vignette('jfa', package = 'jfa')

Usage

evaluation(materiality = NULL, min.precision = NULL, method = 'poisson',
           alternative = c('less', 'two.sided', 'greater'), conf.level = 0.95,
           data = NULL, values = NULL, values.audit = NULL, times = NULL,
           x = NULL, n = NULL, N.units = NULL, N.items = NULL,
           r.delta = 2.7, m.type = 'accounts', cs.a = 1, cs.b = 3, cs.mu = 0.5,
           prior = FALSE)

Arguments

materiality

a numeric value between 0 and 1 specifying the performance materiality (i.e., the maximum tolerable misstatement) as a fraction of the total number of units in the population. Can be NULL, but min.precision should be specified in that case. Not used for methods direct, difference, quotient, and regression.

min.precision

a numeric value between 0 and 1 specifying the minimum precision (i.e., upper bound minus most likely error) as a fraction of the total population size. Can be NULL, but materiality should be specified in that case.

method

a character specifying the inference method. Possible options are poisson (default), binomial, hypergeometric, mpu, stringer, stringer.meikle, stringer.lta, stringer.pvz, rohrbach, moment, direct, difference, quotient, or regression. See the details section for more information.

alternative

a character indicating the alternative hypothesis and the type of confidence / credible interval. Possible options are less (default), two.sided, or greater.

conf.level

a numeric value between 0 and 1 specifying the confidence level.

data

a data frame containing a data sample.

values

a character specifying name of a column in data containing the book values of the items.

values.audit

a character specifying name of a column in data containing the audit (true) values of the items.

times

a character specifying name of a column in data containing the number of times each item in data should be counted (e.g., due to being selected multiple times for the sample).

x

a numeric value larger than 0 specifying the sum of (proportional) misstatements in the sample. If specified, overrides the data, values and values.audit arguments and assumes that the data come from summary statistics specified by both x and n.

n

an integer larger than 0 specifying the number of items in the sample. If specified, overrides the data, values and values.audit arguments and assumes that the data come from summary statistics specified by both x and n.

N.units

an integer larger than 0 specifying the number of units in the population. Only used for methods hypergeometric, direct, difference, quotient, and regression.

N.items

an integer larger than 0 specifying the number of items in the population. Only used for methods direct, difference, quotient, and regression.

r.delta

a numeric value specifying \Delta in Rohrbach's augmented variance bound (Rohrbach, 1993). Only used for method rohrbach.

m.type

a character specifying the type of population (Dworin and Grimlund, 1984). Possible options are accounts and inventory. Only used for method moment.

cs.a

a numeric value specifying the \alpha parameter of the prior distribution on the mean taint. Only used for method coxsnell.

cs.b

a numeric value specifying the \beta parameter of the prior distribution on the mean taint. Only used for method coxsnell.

cs.mu

a numeric value between 0 and 1 specifying the mean of the prior distribution on the mean taint. Only used for method coxsnell.

prior

a logical specifying whether to use a prior distribution, or an object of class jfaPrior or jfaPosterior containing the prior distribution. If FALSE (default), performs classical planning. If TRUE, performs Bayesian planning using a default conjugate prior.

Details

This section lists the available options for the methods argument.

Value

An object of class jfaEvaluation containing:

conf.level

a numeric value between 0 and 1 giving the confidence level.

mle

a numeric value between 0 and 1 giving the most likely error in the population.

ub

a numeric value between 0 and 1 giving the upper bound for the population misstatement.

lb

a numeric value between 0 and 1 giving the lower bound for the population misstatement.

precision

a numeric value between 0 and 1 giving the difference between the most likely error and the upper bound.

p.value

for classical tests, a numeric value giving the one-sided p-value.

x

an integer larger than, or equal to, 0 giving the number of sample errors.

t

a value larger than, or equal to, 0, giving the sum of proportional sample errors.

n

an integer larger than 0 giving the sample size.

materiality

if materiality is specified, a numeric value between 0 and 1 giving the performance materiality as a fraction of the number of units in the population.

min.precision

if min.precision is specified, a numeric value between 0 and 1 giving the minimum precision as a fraction of the number of units in the population.

alternative

a character indicating the alternative hypothesis.

method

a character indicating the inference method.

N.units

if N.units is specified, in integer larger than 0 indicating the number of units in the population.

N.items

if N.items is specified, in integer larger than 0 indicating the number of items in the population.

K

if method = 'hypergeometric', an integer indicating the assumed total errors in the population.

prior

an object of class 'jfaPrior' that contains the prior distribution.

posterior

an object of class 'jfaPosterior' that contains the posterior distribution.

data

a data frame containing the relevant columns from the data.

data.name

a character giving the name of the data.

Author(s)

Koen Derks, k.derks@nyenrode.nl

References

Cox, D. and Snell, E. (1979). On sampling and the estimation of rare errors. Biometrika, 66(1), 125-132.

Derks, K., de Swart, J., van Batenburg, P., Wagenmakers, E.-J., & Wetzels, R. (2021). Priors in a Bayesian audit: How integration of existing information into the prior distribution can improve audit transparency and efficiency. International Journal of Auditing, 25(3), 621-636.

Dworin, L. D. and Grimlund, R. A. (1984). Dollar-unit sampling for accounts receivable and inventory. The Accounting Review, 59(2), 218–241

Leslie, D. A., Teitlebaum, A. D., & Anderson, R. J. (1979). Dollar-unit Sampling: A Practical Guide for Auditors. Copp Clark Pitman; Belmont, Calif.: distributed by Fearon-Pitman.

Meikle, G. R. (1972). Statistical Sampling in an Audit Context: An Audit Technique. Canadian Institute of Chartered Accountants.

Pap, G., and van Zuijlen, M. C. (1996). On the asymptotic behavior of the Stringer bound. Statistica Neerlandica, 50(3), 367-389.

Rohrbach, K. J. (1993). Variance augmentation to achieve nominal coverage probability in sampling from audit populations. Auditing, 12(2), 79.

Stringer, K. W. (1963). Practical aspects of statistical sampling in auditing. In Proceedings of the Business and Economic Statistics Section (pp. 405-411). American Statistical Association.

Touw, P., and Hoogduin, L. (2011). Statistiek voor Audit en Controlling. Boom uitgevers Amsterdam.

See Also

auditPrior planning selection report

Examples

data("BuildIt")

# Draw a sample of 100 monetary units from the population using
# fixed interval monetary unit sampling
sample <- selection(
  data = BuildIt, size = 100, units = "values",
  method = "interval", values = "bookValue"
)$sample

# Classical evaluation using the Stringer bound
evaluation(
  materiality = 0.05, method = "stringer", conf.level = 0.95,
  data = sample, values = "bookValue", values.audit = "auditValue"
)

# Classical evaluation using the Poisson likelihood
evaluation(
  materiality = 0.05, method = "poisson", conf.level = 0.95,
  data = sample, values = "bookValue", values.audit = "auditValue"
)

# Bayesian evaluation using a noninformative gamma prior distribution
evaluation(
  materiality = 0.05, method = "poisson", conf.level = 0.95,
  data = sample, values = "bookValue", values.audit = "auditValue",
  prior = TRUE
)

# Bayesian evaluation using an informed prior distribution
evaluation(
  materiality = 0.05, method = "poisson", conf.level = 0.95,
  data = sample, values = "bookValue", values.audit = "auditValue",
  prior = auditPrior(method = "param", alpha = 1, beta = 10)
)

[Package jfa version 0.6.4 Index]