Dear Statalisters,

I have an unbalanced panel dataset with approx. 12,300 observations and am analysing the effects of leaders exiting their projects (variable name "exit" = 1 if exit takes place and = 0 if no exit takes place) on project performance (count variable) as well as collaboration (count variable) among remaining team members. I declared the data as panel data using
Code:
xtset projectid time
I ran two regressions
Code:
xtnbreg performance control_vars exit, fe
and
Code:
xtnbreg collaboration control_vars exit, fe
Regression results show that exit has a stat. sig. effect on performance as well as collaboration. Now I'd like to illustrate these effects in two graphics. One that shows the average values of "performance" several time periods (say 3) before and after exit=1 takes place. And second, the same graphic analogous for "collaboration": average values of "collaboration" several time periods before and after exit=1 takes place.

I have prepared the following example dataset (The fictional example dataset that I created does not show stat. sig. results.):
Code:
* Example generated by -dataex-. To install: ssc install dataex
clear
input byte(projectid time exit performance collaboration)
1 1 0 3 2
1 2 0 3 2
1 3 0 3 2
1 4 0 4 3
2 3 0 5 3
2 4 1 4 4
2 5 0 5 3
3 1 0 2 3
3 2 1 1 4
3 3 0 2 4
3 4 0 3 4
3 5 0 3 4
3 8 1 2 5
3 9 0 2 2
4 4 0 3 2
4 5 1 2 3
4 6 0 2 3
4 7 0 3 2
4 8 0 4 2
5 1 0 5 2
5 2 0 5 2
5 3 0 5 2
5 4 0 5 5
5 5 0 5 5
6 1 0 5 5
6 2 1 4 6
6 3 0 4 6
6 4 0 5 6
6 5 0 5 5
6 6 0 6 4
6 7 0 6 3
end
Do you got any advice for me? Thank you very much in advance.

Maja