Statalist


[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

Re: st: How to append a dataset using one observation only


From   "Svend Juul" <SJ@SOCI.AU.DK>
To   <statalist@hsphsun2.harvard.edu>
Subject   Re: st: How to append a dataset using one observation only
Date   Fri, 16 Nov 2007 08:47:02 +0100

Tiago wrote:

Due to problems with memory, I would like to know if it is possible to
append a dataset only using a specific observation.

For example, suppose we have the following datasets:

DATASET 01

variable1
1
2
3
4
5
6


DATASET 02

variable1
4
45
12
56
28

The objective is to add to dataset 01 only one out of 5 observations of
dataset 02 without creating a tempfile.

----------------------------------------------------

Start with dataset02 and reduce it:

   use dataset02
   keep in 1       // keep the first observation if that is what you
want
   append dataset01

Hope this helps
Svend
__________________________________________

Svend Juul
Institut for Folkesundhed, Afdeling for Epidemiologi
(Institute of Public Health, Department of Epidemiology)
Vennelyst Boulevard 6
DK-8000  Aarhus C, Denmark
Phone: +45 8942 6090
Home:  +45 8693 7796
Email: sj@soci.au.dk
__________________________________________ 

*
*   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/



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