View source: R/svyciprop_adjusted.R
svyciprop_adjusted | R Documentation |
A version of survey::svyciprop( method = "beta" )
that adjusts for the degrees of freedom.
svyciprop_adjusted(formula, design, level = 0.95, adj = "none", ...)
formula |
see |
design |
see |
level |
see |
adj |
adjustment to the Korn and Graubard confidence intervals: |
... |
see |
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.
The point estimate of the proportion, with the confidence interval as an attribute.
set_survey(namcs2019sv)
set_opts(adj = "NCHS")
tab("AGER")
set_opts(adj = "none")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.