Dear community,
I have a data set enlisting all previous/current occupations of executives (with start and end dates) which further specifies whether this position was at a quoted company or governmental. If sorted by directorid, you have all his/her previous/current positions grouped together. I now want to check whether his governmental career preceeded his company-career. So far I have generated two variables: gen min_gov = min(start) if companytype=="government" and gen min_quoted = min(start) if companytype=="quoted") and would like to assign these value to the WHOLE group and not just to thie specific row. Is there a way to do this?
Thanks in advance!
Marie
Related Posts with assigning values group-wise
What components should I pay attention to when buying a new laptop for Stata?Hello Statalisters, I don't know if I'm allowed to post this thread as it is not related to Stata p…
max # of variables in Cochran's Q test?Hello- I am trying to evaluate multiple choice (non-exclusive) binary questions. Ex: on a survey, a …
De-trending Panel DataHi everyone, I need help with detrending panel data. I have a panel of firm observations across year…
Abnormal return for everday in a yearGood day everybody, I am new to Stata, and came up with an issue regarding the event study. I use t…
How can I get gr_edit to refer to specific graphs when multiple graphs are open in the graph window?I'm using a user-created command (-synth2-) that generates multiple graphs as outputs. I want to be …
Subscribe to:
Post Comments (Atom)
0 Response to assigning values group-wise
Post a Comment