- some bargraph examples
[PyX/mjg.git] / examples / bargraphs / multisubaxis.py
blob923449412856253da42654572335e1a803ac77b0
1 # A multisubaxis allows for subtitles at a multibar
2 # plot. Furthermore it can handle different number of
3 # subbars per main baraxis.
5 from pyx import *
7 a = graph.axis.bar(multisubaxis=graph.axis.bar(dist=0))
9 g = graph.graphxy(width=8, x=a)
10 g.plot([graph.data.list([["A", 5], ["B", 6]], xname=1, y=2),
11 graph.data.list([["A", 7], ["B", 8], ["C", 9]], xname=1, y=2)],
12 [graph.style.barpos(fromvalue=0), graph.style.bar()])
13 g.writeEPSfile("multisubaxis")