2
$\begingroup$

So I want to be able to put axes labels simultaneously as the numerical labels.

I can achieve that with the following, but is there a better/cleaner way? I can't use callout, because I am using version 10.4.0 for Microsoft Windows (64-bit) (February 26, 2016)

names = {cat, dog, monkey}
data = {7,12,3}
BarChart[data, ChartLabels -> names , 
 BarOrigin -> Left, ScalingFunctions -> "Log", AspectRatio -> 2, 
 LabelingFunction -> (Placed[Row[{"$", #}], After] &)]

enter image description here

$\endgroup$

1 Answer 1

4
$\begingroup$

Not necessarily better/cleaner than your approach but you can also add multiple labels using the option ChartLabels only:

BarChart[data,
 ChartLabels -> Placed[{names, Row[{"$", #}] & /@ data}, {Axis, After}],
 BarOrigin -> Left,
 ScalingFunctions -> "Log",
 AspectRatio -> 2]

enter image description here

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.