Dear statalist,
I need your help.
I am doing a job that consists in evaluating how the issue of a specific bond impacts on governance variables (for example independent directors, size of the board, etc.).

First of all, I made a specific pairing with STATA's psmatch2 command, to find three companies more similar to the issuer of this bond, but which are not issuers.I made a psmatch2 with two conditions: year and industry (SIC code).

Now, I have to do DID analysis. To do this I found two problems:
1. create a specific ID for matched pairs
2. create a PRE_POST vector

My difficulty is due to the use of panel data and the nature of the data which requires that each company has issued a bond in different years.
It follows that a control group company can be combined with a company treated in the year 2014 and another company treated in the year 2018.

In this case, I have a hard time finding a specific ID for each match, and creating the time vector(PRE_POST).

I thought to publish the companies that are paired more than once, so they can have a specific ID for each pairing and a PRE_POST consistent with the company being treated.
Would this be statistically correct?
Do you have any other ideas?


Code:
xtlogit TRATTAMENTO logattivo MARKETTOBOOKVALUE ROE ROA BETA id_settore id_stato, fe
/*with a logit function I calculate the propensity score. My covariates are TotalAssets, ROA, ROE, BETA, industry and country (categorical variables) */

predict pscore

gen pscore1=ANNO*10+SIC1*100+pscore    


psmatch2 TRATTAMENTO2, pscore(pscore1) logit
I created a new id with a STATA user code:

Code:
isid _id //    VERIFY ASSUMPTION

drop if missing(_n1)

by _n1(_id), sort: gen _j= _n
reshape wide _id, i(_n1) j(_j)
isid _n1
gen long tuple_id = _n
rename _n1 _id0
reshape long _id, i(tuple_id) j(_j)
drop if missing(_id)
drop _j
sort _id
order _id, first


Code:
* Example generated by -dataex-. To install: ssc install dataex
clear
input int _id long tuple_id
 322  1
 426  2
 511  3
 519  4
 862  5
 874  6
 954  7
1443  8
1554  9
1749 10
2079 11
2098 12
2104 13
2112 14
2121 15
2174 16
2382 17
2389 18
2443 19
2444 20
2445 21
2464 22
2474 23
3526  1
3527  2
3528  3
3529  4
3530  5
3531  6
3532  7
3533  8
3534  9
3535 10
3536 11
3537 12
3538 13
3539 14
3540 15
3541 16
3542 17
3543 18
3544 19
3545 20
3546 21
3547 22
3548 23

end
For example, in this case with _id 862 and 874 are two observations from the same company, but in different years and a tuple_id of 5 and 6 corresponds.
How do I consider this in my panel data analysis?
Would it be correct to duplicate the data and consider the same company once with tuple_id = 5 and another time with tuple_id = 6?

Thank you all