MUS.extend: Extend a MUS sample.

Description Usage Arguments Value Author(s) Examples

Description

Extends a sample that requires further evidence. Works with MUS.extraction.result.

Please treat as experimental.

Usage

1
  MUS.extend(extract, new_plan=NULL, additional.n=NULL)

Arguments

extract

An object of the type MUS.extraction.result to be extended.

new_plan

Provide a new MUS plan. If null, you must provide the qty of items to extend the sample.

additional.n

Ignored if new_plan is provided, otherwise sample will be extended by additional.n items

Value

Returns an extended MUS.extraction.result object.

Author(s)

Andre Guimaraes <[email protected]>

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
## Simple Example
# Assume 500 invoices
mydata <- data.frame(book.value=
  round(c(runif(n=480, min=10,max=20000),
  runif(n=20, min=15000,max=50000)))
)

# Plan a sample and cache it
plan <- MUS.planning(data=mydata,
tolerable.error=50000, expected.error=3000)

# Extract a sample and cache it
extract <- MUS.extraction(plan, obey.n.as.min=TRUE)

# Create a new plan
new_plan <- MUS.planning(data=mydata,
tolerable.error=50000, expected.error=5000)

# extends the sample using the new plan
extended <- MUS.extend(extract, new_plan)

# extends the sample by 20 itens using the original plan
extended20 <- MUS.extend(extract, additional.n=20)

MUS documentation built on May 2, 2019, 12:36 p.m.