I am trying to create a horizontal bar graph grouped by categories. I wanted to add two labels to the bars, one with percentages and one with the count. I have been able to generate these bar graphs individually, but I am not sure how to go about putting it all together.

Code:
graph hbar, over(Condensed_OutcomeMID) over(MID_Dur_Cat) ///
asyvars blabel(bar, format(%9.1f)) ///
name("Outcome_by_duration_per", replace) percentages
graph export Outcome_by_duration_per.jpg, replace

graph hbar (count),over(Condensed_OutcomeMID) over(MID_Dur_Cat) ///
asyvars blabel(bar, format(%9.1f) position(inside) color(gs16)) ///
name("Outcome_by_duration1", replace) 
graph export Outcome_by_duration1.jpg, replace
In the end, I get:

Array

Array

In the end, I'd like the x-axis to be the percentage out of the group, and to just add the count labels within the bars like in the second graph. Also, if anyone has recommendations about how to fix the text issues (with the group labels on the y axis and the legend), I would really appreciate it! I'm still pretty new to Stata so any help is appreciated.