How to change the color for bar graphs and create space between grouped bars?
Mostra commenti meno recenti
Hi How to change the face color of the individual bar in a grouped bar chart. How to create space between different groups in a bar chart.
For example, as shown in the below image. I have 3 different category i.e. A,B,C and each category has 5 bars i.e. 2,5,10 20 and 25. How to create this kind of graph in matlab.

The data for A, B, C are... A= [10,13,9,6,20]' B= [2, 4, 7, 9,10]' C=[-2,-3,-8,-10,-11]'
Thanks
Risposta accettata
Più risposte (2)
R7 DR
il 9 Lug 2017
0 voti
1 Commento
Another Matlab weakpoint -- there's no explaining TMW's failure to include multitude of hatching patterns in lo! these many years.
I've also tried a number of FEX hatching submissions and had only marginal success with any of them, sorry.
The ones I've used worked (to a lesser or greater degree of pleasing success) directly on patch object handles; I don't know about trying them with bar series objects.
In short, I don't know enough specifically to help; I'd suggest it's a big enough oversight to be worth a bug/feature report and enhancement request. I don't recall if I actually submitted one back when was playing with those routines or not; that was a couple years ago now...
Hunter Pruett
il 23 Mag 2020
Modificato: Hunter Pruett
il 23 Mag 2020
0 voti
Just finished the barmod function--controls relative position of just about everything in the plot. Hope this helps anyone else with this question--I was having similar issues and found the lack of functionality a bit disappointing. See the demo for color modification and such.
Categorie
Scopri di più su Discrete Data Plots in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
