using PERWT to contract the data in STATA

I want to contract the data and get (weighted) frequencies of various sub-groups. The STATA commant contract only allows the use of frequency weights. However, STATA does not allow the use of non-integer values in frequency weights. Is rounding perwt a solution to the problem or are there better ways of dealing with this?

The best way to apply sampling weights in Stata is to use the svy command. In addition to setting up sampling weights, this command allows you to specify the strata (using the STRATA variable) that provides additional information about the design of the particular sample. Here is a nice introduction in using the svy in Stata.

1 Like

Hi Jeff, I have the same question. Unfortunately, stata svy does not seem to allow frequency weights with non-integer values either. What would be the solution to using samples with non-integer weights when frequency weights need to be used (like in the contract command that only allows frequency weights)? Many thanks.

Either rounding or truncating the weights seems like a reasonable solution to me.