A version of survey::svyciprop( method = "beta" )
that adjusts for the degrees of freedom.
svyciprop_adjusted(formula, design, level = 0.95, adj = "none", ...)
The point estimate of the proportion, with the confidence interval as an attribute.
see survey::svyciprop()
.
see survey::svyciprop()
.
see survey::svyciprop()
.
adjustment to the Korn and Graubard confidence intervals: "none"
(default),
"NCHS"
, or "NHIS"
.
see survey::svyciprop()
.
adj
specifies the adjustment to the Korn and Graubard confidence intervals.
"none"
: No adjustment is performed. Produces standard Korn and Graubard confidence intervals,
same as survey::svyciprop( method = "beta" )
.
"NCHS"
: Adjustment that might be required by some (though not all) NCHS data systems. With
this adjustment, the degrees of freedom is set to degf(design)
. Consult the documentation
for the data system that you are analyzing to determine if this is the appropriate
adjustment.
"NHIS"
: Adjustment that might be required by NHIS. With this adjustment, the degrees
of freedom is set to nrow(design) - 1
. Consult the documentation
for the data system that you are analyzing to determine if this is the appropriate
adjustment.
To use these adjustments in surveytable
tabulations, call set_survey()
or set_opts()
with the
appropriate mode
or adj
argument.
Originally written by Makram Talih in 2019.
set_survey(namcs2019sv)
set_opts(adj = "NCHS")
tab("AGER")
set_opts(adj = "none")
Run the code above in your browser using DataLab