Hello,
I am trying to use the merge command with the update option. I would like to keep the following observations:
1 master observation appeared in master only
3 match observation appeared in both
4 match_update observation appeared in both, missing values updated
I also want to keep, but NOT to update the missing values from the following observations:
5 match_conflict observation appeared in both, conflicting nonmissing values
I understand that if I specify:
. merge m:1 varlist using file1, keepusing(varlist1) update keep(master match match_update)
the observations for _m = 5 are dropped.
If I specify instead:
. merge m:1 varlist using file1, keepusing(varlist1) update keep(master match match_update match_conflict)
then the missing values are updated for the observations with conflicting non-missing values.
Is there a way to keep observations with _m = 5 but without updating the missing values?
Thanks a lot,
Best
Mariela
I am trying to use the merge command with the update option. I would like to keep the following observations:
1 master observation appeared in master only
3 match observation appeared in both
4 match_update observation appeared in both, missing values updated
I also want to keep, but NOT to update the missing values from the following observations:
5 match_conflict observation appeared in both, conflicting nonmissing values
I understand that if I specify:
. merge m:1 varlist using file1, keepusing(varlist1) update keep(master match match_update)
the observations for _m = 5 are dropped.
If I specify instead:
. merge m:1 varlist using file1, keepusing(varlist1) update keep(master match match_update match_conflict)
then the missing values are updated for the observations with conflicting non-missing values.
Is there a way to keep observations with _m = 5 but without updating the missing values?
Thanks a lot,
Best
Mariela
Comment