I have to compute the relative mean weight of two variables (local taxes called IMI and IMT) considering the total income (over two other variables, called Capital Income and Current Income), using loop-foreach. However, the below comand, that I've been trying, is not working.
local llist "IMI IMT"
. foreach cc of local llist {
2.
. display _new _new "Local tax: `cc'"
3.
. keep if IMI == "`cc'" | IMT == "`cc'"
4.
. reg Cap Cor
5.
. }
Can someone help please?
local llist "IMI IMT"
. foreach cc of local llist {
2.
. display _new _new "Local tax: `cc'"
3.
. keep if IMI == "`cc'" | IMT == "`cc'"
4.
. reg Cap Cor
5.
. }
Can someone help please?

Comment