Hi everyone,
I have a logistic model to test the effect of different individual characteristics on participation in charitable giving.
My model looks like logit charity_participation i.generation sex i.income_class i.educ_level happiness char_conf marital_status i.religion
The variable of interest in generation which I have created recoded the variable from WVS:
gen generation = .
replace generation = 1 if V241 >= 1943 & V241 <= 1963
replace generation = 2 if V241 >= 1964 & V241 <= 1979
replace generation = 3 if V241 >= 1980 & V241 <= 1995
label define gencuts 1 "Baby Boomers" 2 "Generation X" 3 "Millennials"
label values generation gencuts
V241 is a variable which corresponds the birth age of the respondents.
As a result using i.generation in the logic model I can interpret the results for Generation X and Millennials related to the Baby Boomers (difference Millennials and Gen X from Baby Boomers).
My question: I would like to have 3 separate generations to interpret their variables separately (not related to base group - Baby Boomers). Should I then create instead of categorical variable separate variable for each of 3 generations? can you help with the coding in that case?
Thank you in advance.
Related Posts with generate separate group variables instead of categorical variable. Need your help!
How to convert a date variableHi Stata Users, I have a numeric date variable in the data ex below, and I need to split it into tw…
Gen total var for profitability from one year before to two years after given dateDear all, I am trying to sum the profitability of a given target firm for the period year-1 to year…
count if variables meet conditionsHello everyone, I have a data on average sales of corporation for the past 6 months. Below you can s…
Some important statistics at the bottom of x axisI want some statistics that correspond to x-axis and I want the Y axis value to be computed and appe…
How to loop on all CSV files in several folders and create a separate dta filesHi , I am wondering How to loop on all CSV files in several folders and create a separate dta files …
Subscribe to:
Post Comments (Atom)
0 Response to generate separate group variables instead of categorical variable. Need your help!
Post a Comment