exactci (version 1.3-3)

exactpoissonPlot: Plot p-value function for single or pair of poisson responses.

Description

Plots p-values as a function of different point null hypothesis values for rate. For two-sided p-values, can plot three types of p-values: the minimum likelihood method (default for poisson.test), the central method (i.e., twice the one-sided exact p-values), and Blaker's exact.

Usage

exactpoissonPlot(x,
    T=1,
    r=NULL,
    ndiv=1000,
    tsmethod="central",
    rRange=NULL,
    dolog=TRUE,
    dolines=FALSE,
    dopoints=TRUE,
    doci=TRUE, 
    alternative = c("two.sided", "less", "greater"), 
    relErr=1 + 10^(-7), 
    conf.level=.95,
    alphaline=TRUE,
    newplot=TRUE,
    midp=FALSE,...)

Arguments

x

number of events. A vector of length one or two

T

time base for event count. A vector of length one or two

r

null values of rate for plot, if NULL divides rRange into ndiv pieces

ndiv

number of pieces to divide up range of x-axis

tsmethod

two-sided method for p-value calculation, either "minlike","blaker" or "central"

rRange

range for plotting null hypothesis values of rate, if null then uses confidence interval to determine range

dolog

logical, plot horizontal axis in log scale?

dolines

logical, add lines to a plot?

dopoints

logical, add points to a plot?

doci

logical, add lines for confidence interval?

alternative

type of alternative for p-values

relErr

number close to 1, avoids problems with ties, see binomControl

conf.level

confidence level for use when doci=TRUE

alphaline

logical, if doci=TRUE should line be drawn at significance level

newplot

logical,start a new plot?

midp

logical, use mid-p for p-values? Not available for tsmethod='blaker' or 'minlike'

values passed to plot, points, or lines statement

Value

Does graph or adds lines or points. Returns (invisibly, see invisible) a list with elements r (null hypothesis values) and p.value (associated p-values).

See Also

binom.exact

Examples

Run this code
# NOT RUN {
## single Poisson response
exactpoissonPlot(2,17877)
# }

Run the code above in your browser using DataCamp Workspace