Hello,
I want to create a variable that shows the % of increase in care by household. Below, you can see the data. For the simplicity I colored the households and I only showed the child level increase of help and parent level increase of help. What I want is to find parent level increased help divided by the total number of increased help within that household. I am not sure how to do this simple calculation within the household. That would be really nice if anyone can help me.
mergeid parent_level_increased_help) % increase help (variable I want to construct)
"AT-001881-02" 1 50%
"AT-001881-02" 1 50%
"AT-002965-02" 0 0%
"AT-002965-02" 0 .
"AT-002965-02" 0 .
"AT-002965-02" 0
"AT-020460-02" 0
"AT-020460-02" 0
"AT-020460-02" 0
"AT-020460-02" 0
"AT-020975-02" 0
"AT-020975-02" 0
"AT-020975-02" 0
"AT-034810-02" 1
"AT-034810-02" 1
"AT-044265-02" 0
"AT-044265-02" 0
"AT-046816-02" 2
"AT-046816-02" 2
Thanks in advance!
Related Posts with calculating percentages by household id
Latent class analysis: - gsem- & pseudo R-squaredDear users, This may be a dumb question, but I am trying familiarizing myself with Latent class clu…
Problem with specifying count data modelsDear Statalists, I am performing nonlinear regression analysis and despite using several books on m…
Non-linear regression help (constrained output)Dear all, I have been running a non-linear regression on a data-set using the following specificati…
Help with MergeGood Morning, I have some trouble in using the merge command in order to create a panel data on bank…
Stata Command for Graphing placebo test resultsHi Everyone, I am trying to replicate the synthetic control method implemented by Abadie,Diamond, a…
Subscribe to:
Post Comments (Atom)
0 Response to calculating percentages by household id
Post a Comment