Hello. This seems like it would be straightforward but as an advanced beginner I am having a hard time figuring this one out. I am trying to generate new variables that will be used as my pweight. These will be the inverse of the sum of the number of females age 10-14 and males age 10-14 in each school out of the total population surveyed. I I have 3 variables of interest: SchoolName, Age, Sex. SchoolName has 30 different school names, Age is a continuous variable and Sex is male or female. Any insight how to do this would be greatly appreciated.
Thanks,
Adam
Related Posts with Generating a new variable that is the sum of each value of a different variable
How to run a regression using weight by the number of children to each parentDear all, I want to examine the effects of children' s characteristics on their parent health outco…
create utf-8 xml file with tabmultHi everyone, I create a .xml file with various sheets which I later on open in Excel. One sheet has…
how do do a rolling WLS in stataI would like to run a rolling regression in Stata, where in each window the weights of independent v…
Separating string variable with parenthesis and commasHello, I have variable that looks like Experience ('Santo Engineering', '2017-04-30', '2017-05-30'…
Add missing valuesHello, I have the following dataset: Code: * Example generated by -dataex-. To install: ssc inst…
Subscribe to:
Post Comments (Atom)
0 Response to Generating a new variable that is the sum of each value of a different variable
Post a Comment