Search All of the Math Forum:
Views expressed in these public forums are not endorsed by
Drexel University or The Math Forum.


JS
Posts:
49
Registered:
8/4/08


Stack order of patches in barplot
Posted:
Feb 8, 2013 5:20 AM


Hi NG,
I have an axis in which I plot two data sets as bar plots. I have a loop that loads one set, plots it and then loads the next and plots it. The Xvalues are common to both sets. All good, but in some cases a value of the second set is higher than the first, causing it to cover the first bar that was plotted at that xposition. Is there a way to traverse through the graphic objects and then "move up" a shorter bar so that is in front? As far as I can see, the individual patches (bars) do not have handles, so how to get to them?
Thanks very much in advance!
JS
PS I know that I could of course test both values for each xvalue and then simply plot the tallest first, but that is not a very elegant solution IMO..



