RDS.HCG.estimates {RDS} | R Documentation |
Homophily Configuration Graph Estimates
Description
This function computes the Homophily Configuration Graph type estimates for a categorical variable.
Usage
RDS.HCG.estimates(
rds.data,
outcome.variable,
N = NULL,
subset = NULL,
small.fraction = FALSE,
empir.lik = TRUE,
to.factor = FALSE,
cont.breaks = 3
)
Arguments
rds.data |
An |
outcome.variable |
A string giving the name of the variable in the
|
N |
Population size to be used to calculate the empirical likelihood interval. If NULL, this value is taken to be the population.size.mid attribute of the data and if that is not set, no finite population correction is used. |
subset |
An optional criterion to subset |
small.fraction |
Should a small sample fraction be assumed |
empir.lik |
Should confidence intervals be estimated using empirical likelihood. |
to.factor |
force variable to be a factor |
cont.breaks |
If variable is numeric, how many discretization points should be used in the calculation of the weights. |
Value
If the empir.lik
is true, an object of class
rds.interval.estimate
is returned. This is a list with components
estimate
: The numerical point estimate of proportion of thetrait.variable
.interval
: A matrix with six columns and one row per category oftrait.variable
:point estimate
: The HT estimate of the population mean.95% Lower Bound
: Lower 95% confidence bound.95% Upper Bound
: Upper 95% confidence bound.Design Effect
: The design effect of the RDS.s.e.
: Standard error.n
: Count of the number of sample values with that value of the trait.
Otherwise an object of class rds.HCG.estimate
object is returned.
Author(s)
Ian E. Fellows
See Also
RDS.I.estimates
, RDS.II.estimates
, RDS.SS.estimates
Examples
data(fauxtime)
RDS.HCG.estimates(rds.data=fauxtime,outcome.variable='var1')