Minot
Using Stata for Survey Analysis
Page 34
The default statistic is the mean.
Optional statistics
subcommands include mean, sum, max, min, range, sd (standard
deviation), var (variance), skewness, kurtosis, median, and p
n (
nth percentile).
Without the by() option, tabstat is like “summarize” except that it allows you to specify the
list of statistics to be displayed.
With the by() option, tabstat is like "tabulate … summarize” except that tabstat is more
flexible in
the statistics and format
It is very similar to the SPSS command “means”.
Below are several examples of tabstat commands with a description of the table that each will
produce:
tabstat farmsize hhsize, stats(mean max min)
gives mean, max, and min of farmsize &
hhsize
tabstat farmsize hhsize, by(reg4)
gives mean of two variables for each region
tabstat farmsize, stats(median) by(reg4)
gives the median farmsize for each region
And Example 13 shows the output of a tabstat command. The table
indicates that per capita
expenditure is highest in the West and lowest in the East.
Do'stlaringiz bilan baham: