Compute point estimates, $p$-values, and confidence intervals
for a hypothesis test.
This function is an S Version 3 generic (see Methods);
method functions can be written to handle specific
S Version 3 classes of data. Classes which already
have methods for this function include:
seqdesign
a group sequential design object inheriting from
"seqdesign"
or a list of group sequential design objects.
OPTIONAL ARGUMENTS:
K
a vector of analysis times at which to make inferences.
By default,
K are the analysis times of the boundaries of
x.
observed
a vector of observed statistics.
By default,
observed are the boundaries of
x.
The
length(observed) should equal
length(K).
ordering
a character indicating how to compute the confidence intervals:
"m" corresponds to sample mean ordering and
"a" corresponds to analysis time ordering.
upper
if
TRUE, then the $p$-value is computed for the
upper alternative.
conf.level.ci
the confidence level of the confidence intervals.
method
a character string or function giving
the method used for computing a point estimate.
labels
the names of the data pairs
(K, observed);
the
length(labels) should equal
length(K).
This is used for printing and plotting.
...
additional arguments can be passed to
method.
VALUE:
If
x is a
"seqdesign" object, then
the function returns an object of class
"inference.seqdesign".
Otherwise,
if
x is a list of
"seqdesign" objects,
then function returns a list of
"inference.seqdesign" objects.
A
"inference.seqdesign" is a list with components
K
a vector of analysis times.
observed
a vector of the observed statistics.
sample.size
a vector of the sample size at the analysis times.
p.value
a vector of the $p$-values of the observed statistics.
estimate
a vector of the point estimates using method
method.
ci
a
length(K) by 2 matrix giving lower and upper
bounds on the confidence interval.