Hello.
I'm using ESS 2014 database (ESS7e02.0F1.dta).
I have a problem when I'm conducting the regression and interaction.
I want to know how seven independent factors affect the number of cigarette consumptions in Europe.
My dependent variable is the number of cigarette consumption per day
Independent variables are age, gender, income, alcohol consumption, weight, divorce, and education.
I have no problem with proceeding regressions. Following was my command.
----------------------
regress smoking age b1.gender b1.incomedummy b4.alcoholgroup b3.eduhigh weight b1.divorce
----------------------
But I encountered one problem when I tried to compare by countries.
Since cntry is not factor variables but string variables,
I did as following.
----------------------
encode cntry, gen(country)
fre country
----------------------
Now I added country with b10 as my reference category.
----------------------
regress smoking age b1.gender b1.incomedummy b4.alcoholgroup b3.eduhigh weight b1.divorce b10.country
----------------------
But the result is the country number 7 and 10 are skipped. Country 7 is always skipped whenever I change the reference category.
How can I do?
Attached file is the screenshot.
Thank you so much in advance.
I'm using ESS 2014 database (ESS7e02.0F1.dta).
I have a problem when I'm conducting the regression and interaction.
I want to know how seven independent factors affect the number of cigarette consumptions in Europe.
My dependent variable is the number of cigarette consumption per day
Independent variables are age, gender, income, alcohol consumption, weight, divorce, and education.
I have no problem with proceeding regressions. Following was my command.
----------------------
regress smoking age b1.gender b1.incomedummy b4.alcoholgroup b3.eduhigh weight b1.divorce
----------------------
But I encountered one problem when I tried to compare by countries.
Since cntry is not factor variables but string variables,
I did as following.
----------------------
encode cntry, gen(country)
fre country
----------------------
Now I added country with b10 as my reference category.
----------------------
regress smoking age b1.gender b1.incomedummy b4.alcoholgroup b3.eduhigh weight b1.divorce b10.country
----------------------
But the result is the country number 7 and 10 are skipped. Country 7 is always skipped whenever I change the reference category.
How can I do?
Attached file is the screenshot.
Thank you so much in advance.
Comment