Learn R Programming

sensR (version 1.2.2)

findcr: Find the critical value of a one-tailed binomial test

Description

Finds the critical value in a one-tailed binomial test

Usage

findcr(sample.size, alpha = .05, p0 = .5, pd0 = 0,
              type = c("difference", "similarity"))

Arguments

sample.size
the sample size of the binomial test (must be a positve integer)
alpha
the type I error-level of the test (must be between zero and one)
p0
the guessing probability under the null-hypothesis (must be between zero and one); 1/2 for the duotrio and twoAFC tests and 1/3 for the triangle and threeAFC tests
pd0
the proportion of discriminators in the population of interest
type
the type of test

Value

  • The critical value in a one-tailed binomial test, that is, the smallest integer such that the null hypothesis binomial probability of being larger (smaller for similarity hypotheses) than or equal to this number is smaller than or equal to the type I error-level of the test.

Details

The critical value of the standard one-tailed difference test of "no difference" is obtained with pd0 = 0. The probability of a correct answer under the null hypothesis is given by pd0 + p0 * (1 - pd0).

See Also

triangle, twoAFC, threeAFC, duotrio, discrim, discrimPwr, discrimSim, AnotA discrimSS, samediff

Examples

Run this code
## Find the critical value for a triangle test for the level 0.05 test
## with 25 subjects:
findcr(sample.size = 25, , p0 = 1/3)

## Similarity example:
findcr(sample.size = 25, p0 = 1/3, pd0 = .2, type = "simil")

Run the code above in your browser using DataLab