-------------------------------------------------------------------------------
help for brrtab
-------------------------------------------------------------------------------

Two-way tables for survey data, with balance repeated replication (BRR) based s > tandard errors

brrtab varname1 varname2 [weight] [if exp] [in range] [ ,

[survey design options]

brrweight(varlist) fay(#) dof(#)

[tabulate options]

tab(varname) missing

[display items]

cell count row column obs se ci deff deft

[display options]

[ proportion | percent ] nolabel nomarginals format(%fmt) vertical level(#)

[statistic options]

pearson lr null wald llwald noadjust ]

pweights are allowed; see help weights. They may be specified with the command, or by the svyset pweight command.

A set of replicate weights are required. They may be specified through the brrweight option; they need not be respecified for subsequent brr-based commands.

brrtab typed without arguments redisplays previous results. Any of the "display items", "display options", or "statistic options" can be specified when redisplaying with the following exception: wald must be specified at run time.

Description

brrmodel produces two-way tabulations with tests for independence for complex survey data. The method of balanced repeated replication (BRR) is used, in conjunction with a set of user-specified replicate weights, to estimate (co)variances of estimates. This is an alternate method to the Taylor series linearization methods used by Stata's svy-based commands.

Except for the different method of variance calculation, brrtab has identical syntax as svytab. Point estimates are the same as those from svytab; standard errors and tests of independence are different.

{strong}This is a beta test version of the command. As far as I know, everything works as it should, but use at your own risk. Currently, finite population correction factors (FPC) are not supported.

Options unique to brrweight

brrweight() specifies the list of variables that contain the replicate weights for the dataset. The standard errors for the model are based on the variation in the estimates generated across the various weights.

A set of brrweights is required for the analysis. Once the brrweights are specified they are stored as a characteristic of the dataset and need not be respecified in subsequent commands.

fay() specifies the k value that should be used for weighting the estimates, based on Fay's method. The default is zero, meaning that simple averaging will be used. As with the replicate weights, the value for fay() is stored as a characteristic of the dataset once it is specified, and need not be re-specified in subsequent commands.

dof() specifies the degrees of freedom for the analysis. By default, it is equal to the number of replications.

Examples

. brrtab agegrp gender [pw=wgt] , brrw(brrw*) . brrtab, se ci deff [redisplay std. err., etc.] . brrtab, count column obs [redisplay counts, etc.]

. brrtab agegrp gender, count se [compute std. err. of counts] . brrtab, count ci [redisplay CI of counts]

. brrtab agegrp gender, wald [compute Wald test] . brrtab, pearson lr [redisplay pearson and lr tests]

. brrtab agegrp gender, tab(income) [gives income proportions by agegrp and gender]

Saved Results

brrtab generates the same saved results as svytab.

Note that e(cmd) is set to "svytab" in order to allow post-tabulation tests to > function correctly.

Methods and formulae

Point estimates are calculated using aweights, and are identical to those produced by Stata's svytab. The (co)variance matrix of the estimates is formed by calculating

G V = c * SUM [ (B - B(i))(B - B(i))' ] i=1

where B a vector of the estimated cell contents based on the full sample weights, B(i) is the estimated vector using the i'th set of replicate weights, G is the number of replicates, and c is a constant defined as:

1 / G for standard BRR (i.e. fay==0), or

1 / (G*(1-k)^2) for Fay's method.

Acknowledgements

brrtab consists largely of the ado file code from official Stata's svytab command, version 1.1.6, modified to calculate (co)variances differently. I would like to thank Bobby Gutierrez at StataCorp for advice on implementation of BRR.

Author

Nick Winter Cornell University nw53@cornell.edu