Thanks to Kit Baum, there is now a new version of the -dsconcat- package on
SSC. Type -ssc desc dsconcat- for more information.
The -dsconcat- package concatenates a list of Stata data sets on disk into
a single data set in the memory. (It is therefore a multiple-file version
of -use- or -append-.) The new version is written in Stata 7, and has new
options allowing the creation of new variables. These new variables
specify, for each observation in the new data set, the input data set from
which the observation came, and/or the sequential order of the observation
within the input data set. For instance, the user might type
and a new data set is created in memory, containing the concatenation of
data sets -auto1-, -auto2-, -auto3- and -auto4-, together with a new
variable -dsseq- indicating which of the 4 input data sets each observation
came from, and another new variable -obsnum- indicating the sequential
order of the observation in the input data set.
Users who only have Stata 6 can still download the old Stata 6 version of
-dsconcat- from my website at http://www.kcl-phs.org.uk/rogernewson/, which
can be accessed from inside Stata by typing
--
Roger Newson
Lecturer in Medical Statistics
Department of Public Health Sciences
King's College London
5th Floor, Capital House
42 Weston Street
London SE1 3QD
United Kingdom
Tel: 020 7848 6648 International +44 20 7848 6648
Fax: 020 7848 6620 International +44 20 7848 6620
or 020 7848 6605 International +44 20 7848 6605
Email: [email protected]
Opinions expressed are those of the author, not the institution.