Greetings
I am currently working on a demographic and surveillance data. I had a data of 8 years who were married and had children. But there is no parity or birth order variable. I am planning to create this variable by own with little data management and conditions.
Condition is- women should be married in the after the surveillance started (as they can enter into the reproductive space and data has no previous history before surveillance). After adjusting and merging those married women ids, I got around 30 million women, where most of them are repeated due to multiple pregnancies during 8 years. Now, I can drop out the duplicates and find the exact unique mothers (9 million). We recorded their conceptions, births and other reproductive records except birth order or parity.
Birth order: Now I want to put the number of parity for each of the unique mothers against their parity variable from the 30 million of dataset. Such as A women with id (2354334) give live births of 3 children, one miscarriage. She repeated in the 30 million dataset about 4 times. Now, how many times the women repeated with the variable "birthtype" with live births or miscarriage can be the birth order or the parity of the mother (with condition of got married after surveillance started).
My question is how can I do it?
In general, how can I put the count number of each participants repeated over and over again and create a new expected variable?
I am currently working on a demographic and surveillance data. I had a data of 8 years who were married and had children. But there is no parity or birth order variable. I am planning to create this variable by own with little data management and conditions.
Condition is- women should be married in the after the surveillance started (as they can enter into the reproductive space and data has no previous history before surveillance). After adjusting and merging those married women ids, I got around 30 million women, where most of them are repeated due to multiple pregnancies during 8 years. Now, I can drop out the duplicates and find the exact unique mothers (9 million). We recorded their conceptions, births and other reproductive records except birth order or parity.
Birth order: Now I want to put the number of parity for each of the unique mothers against their parity variable from the 30 million of dataset. Such as A women with id (2354334) give live births of 3 children, one miscarriage. She repeated in the 30 million dataset about 4 times. Now, how many times the women repeated with the variable "birthtype" with live births or miscarriage can be the birth order or the parity of the mother (with condition of got married after surveillance started).
My question is how can I do it?
In general, how can I put the count number of each participants repeated over and over again and create a new expected variable?
