I've been asked by powers that be to include the % symbol with blabel(bar) option in a graph bar (asis). I've been spinning wheels for hours googling and playing with gr_edit code, but can't seem to find the right logic. Help/suggestions would be greatly appreciated!
graph bar (asis) sfh_q1 sfh_q2 sfh_q3 sfh_q4 sfh_ytd, over(measure, sort(order) gap(*2.5) label(angle() labsize(tiny))) blabel(bar, position(center) orientation(vertical) size(vsmall) color(white)) bar(1, color(pink)) bar(2, color(ltblue)) bar(3, color(navy)) yline(85, lwidth(vthin) lcolor(black)) ytitle(Percent (%), size(vsmall)) ylabel(0(10)100, labsize(tiny) angle(horizontal) glcolor(gs14) gmax) ymtick(##2) legend(col(5) size(vsmall)) graphregion(fcolor(gs14))
Code:
* Example generated by -dataex-. To install: ssc install dataex clear input float(order sfh_q1 sfh_q2 sfh_q3 sfh_q4 sfh_ytd) str4 measure 1 100 100 80 . 97 "cat1" 2 97 98 100 . 98 "cat2" 3 100 98 100 . 99 "cat3" 4 100 99 100 . 99 "cat4" 5 98 98 93 . 97 "cat5" 6 100 98 100 . 99 "cat6" 7 99 96 97 . 97 "cat7" end
Comment