Tabstat is useful module, permitting one to select statistics to be
displayed. For example:
. tabstat q7a q7b q7c, stats(n mean median) column(s)
variable | N mean p50
-------------+------------------------------
q7a | 254 6.185039 7
q7b | 255 5.011765 5
q7c | 254 5.61811 6
--------------------------------------------
I like means to be displayed to only 2 decimal places. I can format my
variables and ask for formatted output, such as
. format q7a - q7c %9.2f
. tabstat q7a q7b q7c , stats(n mean median) column(s) f
variable | N mean p50
-------------+------------------------------
q7a | 254.00 6.19 7.00
q7b | 255.00 5.01 5.00
q7c | 254.00 5.62 6.00
--------------------------------------------
But then all the table elements are formatted 9.2f!
Is there an easy way to just get means (or any given) column formatted
uniquely?
TIA - Michael Oakes
*
* For searches and help try:
* http://www.stata.com/support/faqs/res/findit.html
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/