cPage: Function to compute a critical value for the Page L...

View source: R/cPage.R

cPageR Documentation

Function to compute a critical value for the Page L distribution.

Description

This function computes the critical value for the Page L distriburion at (or typically in the "Exact" and "Monte Carlo" cases, close to) the given alpha level.

Usage

cPage(alpha, k, n, method=NA, n.mc=10000)

Arguments

alpha

A numeric value between 0 and 1.

k

A numeric value indicating the number of treatments.

n

A numeric value indicating the number of blocks.

method

Either "Exact", "Monte Carlo" or "Asymptotic", indicating the desired distribution. When method=NA, "Exact" will be used if the number of permutations is 10,000 or less. Otherwise, "Monte Carlo" will be used.

n.mc

If method="Monte Carlo", the number of Monte Carlo samples used to estimate the distribution. Otherwise, not used.

Value

Returns a list with "NSM3Ch7c" class containing the following components:

k

number of treatments

n

number of blocks

cutoff.U

upper tail cutoff at or below user-specified alpha

true.alpha.U

true alpha level corresponding to cutoff.U (if method="Exact" or "Monte Carlo")

Author(s)

Grant Schneider

Examples

##Hollander-Wolfe-Chicken Example 7.2 Breaking Strength of Cotton Fibers
#cPage(.0097, 5, 3,"Exact")
cPage(.0097, 5, 3,"Monte Carlo")

NSM3 documentation built on Sept. 8, 2023, 5:52 p.m.

Related to cPage in NSM3...