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 on April 23, and its replacement, is already up and running.

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

st: merge within a range

From   Richard Goldstein <>
To   statalist <>
Subject   st: merge within a range
Date   Thu, 16 Sep 2010 16:55:11 -0400


I have the following merge problem. In one data set I have a start date
and and end date (and, of course, several other variables); in another
data set I have a particular date.  I want to merge the two data sets
with a match occurring if the "particular" date in data set 2 is between
(or equal) to the startdate/enddate in data set 1.

An obvious kludge is to expand the first data set and fill-in the dates
to be consecutive.  If possible, however, I prefer not to do this and am
looking for any suggestions.


*   For searches and help try:

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