Dear Stata Users,
I am using the command countmatch and my variable is numeric. The command is as follows -
countmatch ANALYS1 ANALYS2, by(id) gen(count)
However, I would like to put double/two conditions/restrictions as follows -
countmatch ANALYS1 ANALYS2, by(id year) gen(varname)
Unfortunately, countmatch does not work with two restrictions. Someone please help/suggest an alternative command for this.
Thank you.
I am using the command countmatch and my variable is numeric. The command is as follows -
countmatch ANALYS1 ANALYS2, by(id) gen(count)
However, I would like to put double/two conditions/restrictions as follows -
countmatch ANALYS1 ANALYS2, by(id year) gen(varname)
Unfortunately, countmatch does not work with two restrictions. Someone please help/suggest an alternative command for this.
Thank you.
Comment