dsrTest {dsrTest} | R Documentation |
Tests and Confidence Intervals on Directly Standardized Rates
Description
A number of methods have been proposed for calculating
confidence intervals for directly standardized rates. Ng et al (2008),
compare a number of methods, some of which are implemented here.
The default uses the Gamma method by Fay and Feuer (1997) and
implemented in wspoissonTest
.
Usage
dsrTest(
x,
n,
w,
null.value = NULL,
alternative = c("two.sided", "less", "greater"),
conf.level = 0.95,
mult = 1,
method = c("gamma", "asymptotic", "dobson", "beta", "bootstrap"),
control = list()
)
Arguments
x |
a vector of strata-specific counts. |
n |
a vector of strata-specific time bases for counts. |
w |
a vector of strata-specific weights (or standard populations). |
null.value |
a null hypothesis value of the directly rate, if NULL no test is done. If not NULL, provide in rate per mult. |
alternative |
type of alternative hypothesis. |
conf.level |
confidence level for the returned confidence interval. |
mult |
a factor to multiply the estimate and confidence intervals by, to give rates per mult. |
method |
Method used to perform the test and construct the confidence interval. See details. |
control |
list of arguments / type of modification used for
each method. See details and relevant |
Details
Five classes of method have been implemented here:
"gamma"
Calls
wspoissonTest
. By default uses the Gamma Method proposed by Fay and Feuer (1997). Modifications proposed by Tiwari et al (2006) and Fay and Kim (2017) also implemented - seegammaControl
."asymptotic"
Using the normal approximation of the MLE or transformed MLE distribution - see
asymptoticControl
"dobson"
Uses the method proposed by Dobson et al (1991). Estimating the confidence interval on the unweighted sum is done by calling
poisson.exact
- both the exact method and a mid-p method are possible - see dobsonControl."beta"
Methods based on the beta distribution by Tiwari et al (2006) - see betaControl.
"bootstrap"
Approximate Bootstrap method by Swift (1995). P-values are estimated by solving for p.
For each method there is a control
function that will return a list of
parameters that can be used to define sub-types of each of the broad groups
Value
a list with class "htest"
containing the following
components:
statistic |
number of strata or summands:
|
parameter |
mult |
p.value |
p-value, set to |
conf.int |
confidence interval on the true directly standardized rate |
estimate |
directly standardized rate |
null.value |
null hypothesis value for the DSR |
alternative |
alternative hypothesis type |
method |
description of the method |
data.name |
description of the data |
References
Dobson, AJ, Kuulasmaa, K, Eberle, E and Scherer, J (1991) 'Confidence intervals for weighted sums of Poisson parameters', Statistics in Medicine, 10: 457–462. doi:10.1002/sim.4780100317
Swift, MB (1995). 'Simple confidence intervals for standardized rates based on the approximate bootstrap method', Statistics in Medicine, 14, 1875–1888. doi:10.1002/sim.4780141704.
Fay MP & Feuer EJ (1997). 'Confidence intervals for directly standardized rates: a method based on the gamma distribution. Statistics in Medicine*. 16: 791–801. doi:10.1002/(sici)1097-0258(19970415)16:7<791::aid-sim500>3.0.co;2-# Tiwari RC, Clegg LX, & Zou Z (2006). 'Efficient interval estimation for age-adjusted cancer rates.' Statistical Methods in Medical Research 15: 547–569. doi:10.1177/0962280206070621
Ng HKT, Filardo, G & Zheng G (2008). 'Confidence interval estimating procedures for standardized incidence rates.' Computational Statistics and Data Analysis 52 3501–3516. doi:10.1016/j.csda.2007.11.004
See Also
wspoissonTest
,
poisson.exact
,
gammaControl
,
dobsonControl
,
asymptoticControl
,
betaControl