2

I am finding it a strange issue. I want to make a BarChart as

BarChart[{1, 2, 3, 4}, Frame -> True, 
FrameTicks -> {{{1, 2, 3, 4}, {1, 2, 3, 4}}, {{1, 2, 3, 4}, None}}]

And i want to control FrameTicks according to my will. The strange part is, if I keep one of the axis as None then I get no error as shown below.

But if I mark all four sides of Frame using Frame ticks, it does not give me required result. Can't figure out the problem.

enter image description here

Jens
  • 97,245
  • 7
  • 213
  • 499
zenith
  • 549
  • 1
  • 8
  • 16
  • Code same as shown in question.As you can see, in FrameTicks marked 3 sides of Frame, and left the fourth side as "None". If I put values for fourth side also, it does not give me out put. For example if on place of "None", I put {1,2,3,4}, I get figure with problem it gives following messages A tick style in the value of the Ticks option is not a directive. A tick specification in the value of FrameTicks should be a number or list. – zenith Feb 13 '15 at 11:55
  • BarChart[{1, 2, 3, 4}, Frame -> True, FrameTicks -> {{{1, 2, 3, 4}, {1, 2, 3, 4}}, {{1, 2, 3, 4}, {1, 2, 3, 4}}}] works for me – Kuba Feb 13 '15 at 11:58
  • Not for me. I don't know why – zenith Feb 13 '15 at 12:00
  • What version and os are you working on? Have copied my code, maybe there is a mistake in yours? – Kuba Feb 13 '15 at 12:01
  • Its Mathematica 8.0 and Windows7. The thing is FrameTicks worked well for Plot but strangely not for BarChart – zenith Feb 13 '15 at 12:03
  • I can confirm this bug in version 8. So I'm tagging this as a bug that's specific to that version. – Jens Feb 13 '15 at 23:37

1 Answers1

1

This seems to be a bug in Mathematica version 8, and it can be fixed by specifying the FrameTicks outside of BarChart using a Show wrapper:

Show[BarChart[{1, 2, 3, 4}], Frame -> True, 
 FrameTicks -> {{{1, 2, 3, 4}, {1, 2, 3, 4}}, {{1, 2, 3, 4}, {1, 2, 3,4}}}]

barchart

Jens
  • 97,245
  • 7
  • 213
  • 499