Hi,
I am new to Stata and have a question regarding the merging of rows or cells in Stata. Basically, I have a dataset that looks as follows:
For some cases (C_id 2 and 3) I have multiple observations per variable. Now, however, for the cases with multiple observations the values are stored in seperate rows. What I would like to do is to merge all observations per case in one cell. For example for C_id 3 I would want "Cash", "Liabilities" and "deferred payment" in one cell. I wondered whether I could do this through a code since I have over 20000 observations.
Thank you in advance.
I am new to Stata and have a question regarding the merging of rows or cells in Stata. Basically, I have a dataset that looks as follows:
Code:
* Example generated by -dataex-. To install: ssc install dataex clear input int C_id str130 Targetname str18 Dealmethodofpayment 1 "Komioil OOO" "" 2 "Vattenfall Europe Mining AG" "Cash assumed" . "Vattenfall Europe Generation AG" "" 3 "Sibur Kholding OAO" "Cash" . "" "Liabilities" . "" "Deferred payment" end
Thank you in advance.
Comment