Dear all,
First of all, Happy New Year!
I have a question on generating a variable that gives a value that is lowest amongst several variables.
So I have a couple data and need to create a variable that shows the youngest age of children.
The age of children is coded as "age_household member1", "age_household member2", "age_household member3"...
For example, if a father has three children, then their ages are coded like this:
"age_household member1" = 10
"age_household member2" = 12
"age_household member3" = 14
With these information, I need to generate a "youngest age of child" variable. In that case, the value of this variable would be 10.
It takes lots of steps to generate this variable with the codes I know. I would like to ask you if you know a simpler and better way to generate this variable.
Thank you very much in advance for your assistance..!
First of all, Happy New Year!
I have a question on generating a variable that gives a value that is lowest amongst several variables.
So I have a couple data and need to create a variable that shows the youngest age of children.
The age of children is coded as "age_household member1", "age_household member2", "age_household member3"...
For example, if a father has three children, then their ages are coded like this:
"age_household member1" = 10
"age_household member2" = 12
"age_household member3" = 14
With these information, I need to generate a "youngest age of child" variable. In that case, the value of this variable would be 10.
It takes lots of steps to generate this variable with the codes I know. I would like to ask you if you know a simpler and better way to generate this variable.
Thank you very much in advance for your assistance..!
Comment