I am trying to order the legend with the better outcome group up top in the legend and the worse outcome at the bottom. I am unable to finagle to get the right options. Tried fiddling with plot and legend(order) but I can't seem to get it right. Needed "Missense" up top in the legend and then the "Other" below it.
local v mis2
foreach var of local v{
qui sts graph ///
, by(`v') ///
plot1(lc(navy) lp(solid)) ///
plot2(lc(dkorange) lp(-)) ///
plotregion(margin(medium) icolor(white) color(white) ) ///
graphregion(margin(vsmall) icolor(white) color(white) ) ///
title("24-month (OS) analysis", size(medium)) ///
xtitle("Time since tMN/AML diagnosis (months)", size(small)) ///
xlabel(0(5)25, labs(small)) ylabel(0(0.25)1, angle(0) labs(small)) ///
ytitle("Proportion surviving", size(small) margin(medium)) ///
legend(order(1 "Other TP53 mutations (n = )" 2 "Missense P53 mutations (n= )") ///
col(1) size(small) symxsize(*0.5) margin(small) rowg(*0.1) ring(0) pos(2)) ///
risktable(,order(1 "Other" 2 "Missense") size(vsmall) title(,size(small))) ///
text(0.28 8 "p<0.04", place(sw) size(small)) ///
name(km_OS24, replace)Array
0 Response to Ordering legend only in graph
Post a Comment