Hi,
I tried to do a bar figure with 4 groups and to check how many are very happy in each group.
Right now it is not good because I know that in group 1 there are much more observations and that the bar for group 1 is very high relative to the others because of this. Inside group 1 the percentage suppose to be around 30%.
So, can I check the percentage in each group alone? How can I make a bar graph with groups in x axis and percentage within the group in y axis?
I tried to find in stata's guide or here in the forum but I didn't find it.
My code now:
The graph now:

Thank you!
I tried to do a bar figure with 4 groups and to check how many are very happy in each group.
Right now it is not good because I know that in group 1 there are much more observations and that the bar for group 1 is very high relative to the others because of this. Inside group 1 the percentage suppose to be around 30%.
So, can I check the percentage in each group alone? How can I make a bar graph with groups in x axis and percentage within the group in y axis?
I tried to find in stata's guide or here in the forum but I didn't find it.
My code now:
Code:
graph bar (percent) vhappy, over(career_married), if female==1 & college==1
Thank you!
Comment