add ...
[PyX/mjg.git] / examples / axis / parter.txt
blob1315e3dfa342181f57b2057cd338a6be35e7add3
1 Manual parters and rational number arithmetics
3 Partitioners (in the code the short form `parter` is used all over the place)
4 take care of calculating appropriate tick positions for a given axis range.
5 Automatic partitioners create several tick lists, which are than rated by an
6 axis rater instance afterwards. In contrast manual partitioners create a single
7 tick list only, which thus doesn't need to be rated at all. ...
9 In this example we create a manual partitioner, which places ticks with a
10 distance of 1/3 and subticks with a distance of 1/6. We than use this
11 partitioner at two axis, which are identical except for a texter instance to
12 show you another feature of the axes in PyX, namely the rational number
13 arithmetics used to place ticks. The rational numbers are preserved throughout
14 the whole process of merging ticks, until the texter finally needs to output
15 the rational numbers. And at the very end the decimal texter steps into the
16 problem to create a proper representation for the frations. The solution is
17 shown at the left part of the example: the texter marks a period to express the
18 fraction.
20 Alternatively you can use the rational texter to display the values by
21 fractions directly.