Bookmark and Share

Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down at the end of May, and its replacement, statalist.org is already up and running.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

st: New command -stat2data- available for download


From   "P. Wilner Jeanty" <pwjeanty@gmail.com>
To   statalist@hsphsun2.harvard.edu
Subject   st: New command -stat2data- available for download
Date   Fri, 23 Dec 2011 22:30:49 -0600

Hi All,

Thanks to Kit Baum, a new stata command, -stat2data-, is now available
for download from SSC. -stat2data-, a wrapper for the Stata's official
tabstat command, generates a dataset of descriptive statistics
calculated for a list of variables.  stat2data's output is different
from that of collapsing a dataset using the collapse command. In the
dataset generated by -stat2data-, the statistics are in columns and
the variables for which the statistics were calculated are in rows.

To install, type:

. ssc install stat2data



Example:

        . sysuse auto, clear

        . stat2data price mpg trunk weight length turn,
saving(statdata) by(rep78) stat(mean sd k sk q) missing

        . preserve

        . use statdata, clear

        . list

        . restore


Happy Holidays,

Wilner

---------------------------------------------
P. Wilner Jeanty, Rice University
MS 208 6100 Main Street Houston, TX 77005
Phone: (713) 348-3114
Email: pwjeanty@rice.edu
Web:   http://ideas.repec.org/e/pje95.html
           http://www.stasacode.com
*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/


© Copyright 1996–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   Site index