Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
st: -writeinput- available from SSC Archives
From
Eric Booth <[email protected]>
To
"[email protected]" <[email protected]>
Subject
st: -writeinput- available from SSC Archives
Date
Tue, 26 Apr 2011 04:35:18 +0000
<>
Thanks to Kit Baum, a new program -writeinput- is now available from SSC. Stata 9.2 is required. Use -ssc- to install if interested.
-writeinput- is a convenient way to create a snippet of your data for inclusion in a do-file, a Statalist posting (much in the spirit of the Statalist FAQ), or self-contained examples provided to students or colleges. Many times, having a snapshot of the data to share in a Statalist question or response reduces the chance of confusion or various interpretations of what is being asked.
However, creating a good example isn't always straightforward. Sometimes users may adapt a canned dataset or give code for for -generate-ing some illustrative variables; other times they may try to describe the data structure or perhaps paste some data into an email. Poor descriptions of data and poorly pasted/wrapped dataset examples are frequent culprits on Statalist. A good solution is to create an -input- command to write the dataset used in the example and include this -input- command in your Statalist posting or do-file example, but this can be tedious. The user must indicate in variable formats for the varlist and put double quotes around string variable values with embedded spaces in the -input- command.
-writeinput- eases the process of creating an example dataset by writing to a do-file the -input- command for an entire dataset or a subset of your data (selected by a varlist, if, or in conditions). More on this command is available by typing -help writeinput- after installing the program or by visiting my webpage at http://researchnotes.eric-a-booth.com.
- Eric
__
Eric A. Booth
Public Policy Research Institute
Texas A&M University
[email protected]
Office: +979.845.6754
*
* 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/