testQuantiles: Function to test quantile equality for theoretical and...

Description Usage Arguments Details Value See Also

Description

Function to test quantile equality for theoretical and observed distributions

Usage

1
2
testQuantiles(theoreticalCumDist, observedCumDist, numTotalCounts,
  numSEsToCheck, errorMessage)

Arguments

theoreticalCumDist

for (unspecified) value of x, P(X<=x)

observedCumDist

for (unspecified) value of x, observed Fraction(values<=x) = Num(values<=x)/Num(total values). Actual values of x must be the same as those for corresponding entries in theoreticalCumDist

numTotalCounts

Num(total values) (see argument observedCumDist)

numSEsToCheck

number of standard errors to go in each direction from theoretical quantity to see if the estimate falls into the confidence interval

errorMessage

error message to return if observed fraction falls outside of confidence interval

Details

For some random variable X, observed sample x1, x2, .., xN, and attainable value x, we compare theoretical P(X<=x) to observed Num(xi <= x)/N.

Value

TRUE (all tests were passed, otherwise exits with error message).

See Also

Other unitTestsFunctions: testNumericDiff


MBASED documentation built on Nov. 8, 2020, 5:53 p.m.