iscambinomtest: Exact Binomial Test

iscambinomtestR Documentation

Exact Binomial Test

Description

binomtest calculates performs an exact binomial test and graphs the binomial distribution and/or binomial confidence interval.

Usage

iscambinomtest(
  observed,
  n,
  hypothesized = NULL,
  alternative,
  conf.level = NULL,
  verbose = TRUE
)

Arguments

observed

The observed number of successes or sample proportion (assumed to be proportion if value less than one.)

n

number of trials.

hypothesized

hypothesized probability of success.

alternative

"less", "greater", or "two.sided"

conf.level

Confidence level for a two-sided confidence interval.

verbose

Logical, defaults to TRUE. Set to FALSE to suppress messages

Value

a list of the p-value along with lower and upper bound for the calculated confidence interval.

Examples


iscambinomtest(
  observed = 17,
  n = 25,
  hypothesized = 0.5,
  alternative = "greater"
)

iscambinomtest(
  observed = 12,
  n = 80,
  hypothesized = 0.10,
  alternative = "two.sided",
  conf.level = 0.95
)

iscambinomtest(
  observed = 0.14,
  n = 100,
  hypothesized = 0.20,
  alternative = "less"
)

iscambinomtest(observed = 17, n = 25, conf.level = 0.95)

iscambinomtest(observed = 12, n = 80, conf.level = c(0.90, 0.95, 0.99))

ISCAM documentation built on Feb. 12, 2026, 5:07 p.m.