line.estimate: Compute an estimate and standard error from ACS PUMS data.

Description Usage Arguments Value Examples

View source: R/line.estimate.R

Description

Compute point estimate, standard error and 90 of any statistic on ACS PUMS data using the direct method, involving replicate weights and return results on one line.

Usage

1
line.estimate(x, f, ..., result.name = NULL)

Arguments

x

a data frame of PUMS data.

f

a function to calculate the statistic. It must take data and a weight replicate number called wt.rep.num with a default value of NULL.

...

other data passed to f

result.name

name of estimate column in result. Default of NULL uses deparse(substitute(f)).

Value

the point estimate, standard error and 90 for the size of this sample.

Examples

1
2
3
4
5
6
# Number of households in Washington State in 2016
line.estimate(wa.house16, estimate)

# Fraction of Washington State households that rent for cash
line.estimate(subset(wa.house16, TEN==3), proportion, wa.house16,
              result.name='Renters.Pct')

davidthaler/PUMSutils documentation built on July 13, 2019, 9:58 a.m.