From: Arnd B. <arn...@we...> - 2006-02-19 21:32:59
|
Hi, I have a presumably very simple question, but cannot see the solution: How can one get get ticks pointing outward on the y2 axis? The following does not work: ######################################## import pyx xpaint = pyx.graph.axis.painter.regular(innerticklength=0, outerticklength=pyx.graph.axis.painter.ticklength.Long) ypaint = pyx.graph.axis.painter.regular(innerticklength=0, outerticklength=pyx.graph.axis.painter.ticklength.Long) y2paint = pyx.graph.axis.painter.regular(innerticklength=0, outerticklength=pyx.graph.axis.painter.ticklength.Long) g = pyx.graph.graphxy(width=10, x=pyx.graph.axis.linear(min=0, max=5, painter=xpaint), y=pyx.graph.axis.linear(painter=ypaint), # Q: how to get ticks pointing outward here? #y2=pyx.graph.axis.linear(painter=y2paint) ) g.plot(pyx.graph.data.function("y(x)=sin(x)")) g.writeEPSfile("test_painter.eps") ######################################## Uncommenting the line #y2=pyx.graph.axis.linear(painter=y2paint) gives raise RuntimeError("incomplete axis range%s" % errorname) RuntimeError: incomplete axis range for axis y2 Can one somehow get a couple range for y2, but specify a different painter? Usually the plan to post a question leads to the answer, but this time it did not work...;-) Many thanks, Arnd |