Hi Mark ! Thank you so much, I will try this! Actually the displacement year is not the last record of each id infortunetaly, because an id can find a work in a new firm the next year or even several years after and reappear in the panel .. nevertheless I can use id x firm identifier as if a worker is displaced the code id x identifier will appear for the last time. I just have to check if this id is in the firm for at lest 4 years to do that .. I already used the id x firm code to identify displaced id that are reemployed the next year. I compared the last.idxfirm year to the last.id year and if these two are different in two year (the first year being the displacement year) then the worker is reemplyed. Maybe this info will help me! I will also have to do the same exercise for salary_T_plus_1 salaryT_plus_2 etc until 4 (the year when the id does not appear in the record because he is not employed will be marked as "0 salary".. I have thus to replace lag by what ? Thank you so much ! Eugénie
... View more