RE: Problem with FrameTicks and BarLabels

*To*: mathgroup at smc.vnet.net*Subject*: [mg81168] RE: [mg81123] Problem with FrameTicks and BarLabels*From*: "David Annetts" <davidannetts at aapt.net.au>*Date*: Fri, 14 Sep 2007 03:42:12 -0400 (EDT)*References*: <200709131026.GAA15740@smc.vnet.net>

Hi Tom, > I would like tick marks only where there is a Tick Mark Label > on the below graph ((using version 6) : > > Show[BarChart[{97, 2345, 89}, BarOrientation -> Horizontal, > BarLabels -> {"a", "b", "c"}, > GridLines -> {{0, 500, 1000, 1500, 2000, 3000}, None}]] > > However, if I stipulate FrameTicks, I lose my BarLabels, and > am not allowed to put anything but a number into FrameTicks : > > Show[BarChart[{97, 2345, 89}, BarOrientation -> Horizontal, > BarLabels -> {"a", "b", "c"}, Frame -> True, > FrameTicks -> {{None, None}, {{0, 500, 1000, 1500, 2000, 3000}, > None}}, GridLines -> {{0, 500, 1000, 1500, 2000, 3000}, None}]] > > Any ideas how I can get the BarLabels back but retain the new > FrameTicks ? The way to do this, as prompted by a similar question a few months ago from Nasser Abbasi answered by Jean-Marc Gulliet amongst others, seems to be to roll your own ticks. Defining ytik = Transpose[{Range[3], {"a", "b", "c"}}] Then Show[BarChart[{97, 2345, 89}, BarOrientation -> Horizontal, Frame -> True, FrameTicks -> {{ytik, None}, {{0, 500, 1000, 1500, 2000, 3000}, None}}, GridLines -> {{0, 500, 1000, 1500, 2000, 3000}, None}] ] Works fine. Regards, Dave.

**References**:**Problem with FrameTicks and BarLabels***From:*tomfabtastic@hotmail.com