testing_prior: Testing prior for two proportions

Description Usage Arguments Value Author(s) Examples

View source: R/testing_prior.R

Description

Constructs a discrete distribution for two proportions under a testing or uniform hypotheses

Usage

1
2
  testing_prior(lo=.1, hi=.9, n_values=9,
        pequal=0.5, uniform=FALSE)

Arguments

lo

minimum value of each proportion

hi

maximum value of each proportion

n_values

number of values of each proportion

pequal

probability of the equality of the two proportions

uniform

indicates if a uniform prior is desired

Value

matrix of probabilities where the rows and columns are labeled by the values of the proportions

Author(s)

Jim Albert

Examples

1
2
3
4
5
  # testing prior where each proportion is
  # .1, .3, .5, .7, .9
  Prob <- testing_prior(.1, .9, 5)
  # uniform prior over same proportion values
  Prob <- testing_prior(.1, .9, 5, uniform=TRUE)

TeachBayes documentation built on May 1, 2019, 9:17 p.m.