Learn R Programming

NSUM (version 1.0)

killworth: Calculate Killworth Estimates

Description

This function calculates the Killworth estimates for unknown subpopulation sizes based on NSUM data.

Usage

killworth(dat, known, N)

Arguments

dat
a matrix of non-negagtive integers, the (i,k)-th entry represents the number of people that the i-th individual knows from the k-th subpopulation.
known
a vector of positive numbers, the sizes of known subpopulations. All additional columns of dat are treated as unknown.
N
a positive number, the (known) total population size.

Value

A vector of positive numbers with length equal to the number of unknown subpopulations, the Killworth estimates of the subpopulation sizes.

Details

The function killworth allows for the estimation of subpopulation sizes from Killworth's network scale-up model. These estimates can be used to compare with the MCMC results in this package. For reasonable starting values for the MCMC function nsum.mcmc, see the function killworth.start.

References

Killworth, P., Johnsen, E., McCarty, C., Shelley, G., and Bernard, H. (1998a), "A Social Network Approach to Estimating Seroprevalence in the United States," Social Networks, 20, 23-50.

Killworth, P., McCarty, C., Bernard, H., Shelley, G., and Johnsen, E. (1998b), "Estimation of Seroprevalence, Rape, and Homelessness in the United States using a Social Network Approach," Evaluation Review, 22, 289-308.

See Also

killworth.start

Examples

Run this code
## load data
data(McCarty)

## simulate from model with barrier effects
sim.bar <- with(McCarty, nsum.simulate(100, known, unknown, N, model="barrier",
                                       mu, sigma, rho))

## estimate unknown population sizes
dat.bar <- sim.bar$y
NK.killworth <- with(McCarty, killworth(dat.bar, known, N))

Run the code above in your browser using DataLab