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

re: st: problems with joinby or merge

From   Kit Baum <>
Subject   re: st: problems with joinby or merge
Date   Mon, 11 May 2009 12:15:47 -0400

Lots of MISSING VALUES FOR several of the individulas.
Can someone let me know what Im doing wrong? How can I add variables for each of the individuals?

Look at the data on your merge variable, Governorate, In the indiv dataset it ranges from 1-18. In the area dataset it ranges from 11-35. Obviously with a merge all those individuals with 1-10 values will not be matched. You should ALWAYS examine the _merge variable after a merge and think about what it is telling you. In this case it would identify cases = 1 (only in indiv dataset) and cases = 2 (only in gov. dataset -- potentially not a problem if the individuals only come from part of the country) as well as cases = 3 (merged).

The fact that there are 18 distinct values of Governorate in the area file suggests that you might need to recode the values in the indiv. dataset.

Kit Baum   |   Boston College Economics & DIW Berlin   |
An Introduction to Stata Programming |
   An Introduction to Modern Econometrics Using Stata  |

*   For searches and help try:

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