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]
Re: st: Merging question for a panel dataset
From
Jonathan Eggleston <[email protected]>
To
[email protected]
Subject
Re: st: Merging question for a panel dataset
Date
Mon, 13 Sep 2010 22:18:20 -0400
I figured it out, it was less complicated than I thought, a merge
command followed by a reshape long statement got me the dataset I needed.
On 9/13/2010 5:21 PM, Anders Alexandersson wrote:
Jonathan, why is -merge- or -append- not applicable to your situation?
Can you provide some example data that shows the problem?
What is your key variable in addition to pid? That is, what is your
within-id identifier (subobservation), e.g., year or wave?
Are there few or many variables in each of the two datasets (asked to
figure out whether merge or append might be better)?
You can look into -joinby- and -cross- if you instead are trying to
create pairwise combinations.
Anders Alexandersson
[email protected]
On Mon, Sep 13, 2010 at 4:58 PM, Jonathan Eggleston
<[email protected]> wrote:
Im trying to combine varies waves of this one dataset (The British Household
Panel Survey) into one panel dataset. Each wave is one year, and the dataset
and variables for a particular year start with a specific letter. So for
example I’m trying to combine the datasets bindresp and cindresp for the
variables bhowlng and chowlng (these are the same variable, just for
different years). The person id variable is pid, and there are some
individuals that are in some waves but not others. Can anyone suggest some
stata code that will combine the datasets? I’m familiar with the merge and
append commands, but examples I find aren’t quite applicable to my
situation. Thanks!
*
* 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/
*
* 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/