## you have to write code below every line that starts with #. Lines that start with ##provide explanations
# clear the workspace
# load the qog_bas_cs_jan24.csv data
# create a table of the variable p_polity2
# create a new variable p_polity2_cat that has the value "Autocracy" if p_polity2 is -6 or lower, "Anocracy" if p_polity2 is between -5 and 5, and "Democracy" if p_polity2 is 6 or higher.
# compute the mean value of top_top10_income_share for countries that are autocracies
# compute the mean value of top_top10_income_share for countries that are anocracies
# compute the mean value of top_top10_income_share for countries that are democracies
# create a new variable called nelda_mbbe_2 that has the same values as nelda_mbbe
# then, in nelda_mbbe_2, change the observations that have a value of 3 to having a value of 0.5
# do the two last two steps for the variables nelda_mtop, nelda_oa, and nelda_rpae as well
# create a variable nelda_index that is the average of nelda_mbbe_2, nelda_mtop_2, nelda_oa_2, and nelda_rpae_2
# finally compute the mean valaues of nelda_index for autocracies, anocracies, and democracies