probeDist: Check a given result in a distribution

Description Usage Arguments Value Examples

View source: R/mtest.R

Description

Once a distribution of results has been calculated with bernDist and possibly calCumul, this function returns information on a particular result

Usage

1
probeDist(l, experiments)

Arguments

l

List containing each possible result with the same number of experiments, tries and outcomes as the original input. Usually, this will be the output of bernDist.

experiments

List of multinomial trials. Each trial is codified as a vector with the number of results in each category. The number and order of categories must be the same in every experiment. In a binomial experiment, this would be c(number_of_successes, number_of_failures). The function also accepts a matrix (one column per experiment).

Value

Data calculated for experiment in l. This includes the matricial description of the result (desc), the total number of times each outcome was measured (sdesc) and the absolute probability of the result (val). If calCumul has been run, it will also show the cumulative probability (cval). If the experiment is not found in l, the function returns NULL.

Examples

1
2
3
r <- bernDist(list(c(8, 2), c(4, 7)))
s <- calCumul(r)
t <- probeDist(s, list(c(8, 2), c(4, 7)))

vqf/mtest documentation built on Dec. 23, 2021, 4:11 p.m.