Dear all
I am wanting to create an employment rate variable (ie. Number employed/ (Labour Force) * 100) from an employment rate binary variable (=1 if employed and 0 otherwise).
What i have done so far:
egen CountT = count(EMPL) if EMPL == 1
* CountT is total employed (strict)
egen countT = count(EMPL) if EMPL == 0
gen LabourForce = CountT + countT
gen EmplRate = 100 * (CountT / LabourForce)
However, stata does not like me adding the CountT and countT together like that - tabbing it doesn't present anything.
Furthermore, how do you create a cumulative variable for number of employed people. I want to create a cumulative variable from the EMPL binary variable when it = 1. This is so that i can use it as my dependent variable for an lpoly graph.
How do you do that?
Regards
Related Posts with Employment binary variable into employment rate and continuous variable
Upon saving my stata ouput as a .tex file, sigificance is disappearing. Why is this happening?hi statalist, I am having a peculiar problem while using estout to save my output as a tex file. I …
comparing the effect and magnitude of two coefficients across two modelsHello everyone, I have a panel dataset with 500 banks (in 20 countries) over the period 2000-2015. …
Updated combomarginsplotGreetings, An updated combomarginsplot is now available on SSC (thanks Kit Baum!). This version has…
U test for Inverted U-shapeHello, I am looking at whether there is a threshold upon which the total value traded of all stocks…
How to calculate standardized mean difference using ipdmetan (two-stage IPD meta-analysis)?Hi everyone, I'm running a two-stage IPD meta-analysis by using ipdmetan: ipdmetan, study(StudyID) …
Subscribe to:
Post Comments (Atom)
0 Response to Employment binary variable into employment rate and continuous variable
Post a Comment