I want to create a variable which counts the total number of people on a company board per year. The difficulty is that the number changes every year. I have 20 dummy variables for every year, equaling to 1 if the person is present on board, and 0 if not present. I also have a variable id, with a unique number for every company. I can see the total board members per company when I tab id y2020. How can I create this into a variable, which counts the total number of board members, per company, for each year hence calculating Board Size?
Related Posts with Creating a New Variable from a Dummy Variable
Pescadf: not reporting value of test statistic and p-valueHi all, I have an unbalanced panel of around 900 companies for a period of 81 months. I have used t…
Add labels in twoway scatter plotsHi all, very simple question: I would like to add the labels to the variables I have in my twoway sc…
Reshape help for household dataStata novice here so please be gentle, but I have a dataset from a household survey. Basic demograph…
Graphical analysis of ratesHello, I am new to STATA and am using Version 15. Due to the confidential nature of my data I canno…
Comparing rates in stataHello, I am new to STATA and am using Version 15. Due to the confidential nature of my data I canno…
Subscribe to:
Post Comments (Atom)
0 Response to Creating a New Variable from a Dummy Variable
Post a Comment