0
$\begingroup$

I want to create another y axis for just the last group of values, because as you can see, these observation are not comparable with the previous ones.

I would like also a method to distinguish better the labels as for example a code to make the bar chart bigger.

Thanks.

This is my code

data = {{0.074, 0.068, 0.071, 0.080}, {0.091, 0.088, 0.087, 
    0.100}, {0.133, 0.127, 0.130, 0.143}, {0.825, 1.012, 0.817, 
    0.881}};

levels = Map[GrayLevel, {0.15, 0.35, 0.65, 0.95}];

styles = {levels, levels, levels, levels};

GEO = BarChart[MapThread[Style, {data, styles}, 2],
  BarSpacing -> {0.15, 1}, PlotTheme -> "Business", 
  ChartLegends -> {Text[Style["BXE", 12]], Text[Style["CXE", 12]], 
    Text[Style["TQ", 12]], Text[Style["TQ", 12]]},
  ChartStyle -> levels, LabelingFunction -> Above,

  ChartLabels -> {{"a ", "b", "c","d"}, None}, 
  BaseStyle -> Directive[FontSize -> 11]]

enter image description here

$\endgroup$
  • $\begingroup$ Try the attribute FrameTicks -> All. $\endgroup$ – Anjan Kumar Feb 18 '17 at 23:59
  • $\begingroup$ I would rather strongly argue against pursuing the double-axis approach. The entire point of a bar chart is in the fact that the ratios of size / height of the bars represents a similar meaningful relationship within the data. If this proportionality is disrupted by representing them "at different scale", then the resulting bar chart is misleading at best. $\endgroup$ – MarcoB Feb 19 '17 at 5:41

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.