Dear Statalist,

I have an unbalanced panel with ca. 200 firms, and between 3-8 years of data for each firm. In total, there are around 1100 observations (see data example below)

I want to test if the effect of firm size (SIZE) on return on equity (ROE) is different across industries. For this purpose, I have come across different methods that could help me:

(1) Estimate a separate regression for each industry and then compare the coefficients associated with SIZE:
e.g.: xtreg ROE SIZE if industry8==1, fe robust

(2) Estimate one regression and let industry dummies interact with SIZE:
e.g: xtreg ROE SIZE industry8*SIZE industry9*SIZE ... industryX*SIZE, fe robust

(3) Estimate industry fixed effects: I am not sure how to perform this and interpret the results. I tried the following:
xtset industry year
xtreg ROE SIZE, fe vce(cluster industry)
But this gives me the following error: repeated time values within panel


So, my question is:
(i) Which of these methods (if any) should I use to test whether the effect of SIZE on ROE is different for firms across industries
(ii) How do I implement it correctly in STATA? (Depends on the answer of the first question)
(iii) How would you solve the problem if SIZE^2 is included as an additional explanatory variable?

I would appreciate any help.


Code:
* Example generated by -dataex-. To install: ssc install dataex
clear
input int Company_num float(ROE SIZE industry)

10    .2027649 16.423996  8
10  -.06490728 16.777615  8
10    .1564562 16.957634  8
10  -1.3700558 16.587175  8
11    .2409944 14.614808 10
11 -.019694684 14.764834 10
11     .340615 15.061542 10
11    .4010344 15.282972 10
11    .4155528  15.50252 10
11    .3101843 15.766982 10
11   .20718624 16.028524 10
11    .1902793 16.139278 10
12  -.11885364  13.42089  5
12   .05883176 13.731207  5
12  -.05271904 13.727402  5
12  -.22898807  13.66704  5
end