Ask Your Question

modify axe scale

asked 2013-06-17 10:31:08 +0200

vdelecroix gravatar image


I would like to choose which numbers appear on the axes of a graphics. If I do

sage: G = Graphics()
sage: G.set_axes_range(xmin=0,xmax=10,ymin=0,ymax=1)

Then the x axis has a small separation each 2 (ie the numbers 0,2,4,6,8,10 appear). What should I do to get it 3 (ie separation at 0,3,6,9) ?


edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2013-06-17 10:40:48 +0200

kcrisman gravatar image

You mean like this?


There is a lot more information about custom ticks in the plot and graphics documentation.

edit flag offensive delete link more


Wonderful ! I was not able to find it in the documentation. Many thanks.

vdelecroix gravatar imagevdelecroix ( 2013-06-17 15:51:17 +0200 )edit

Sorry, I am not completely happy... Is this only a method to show ? I would like to use it inside a graphics array (with different ticks on each picture).

vdelecroix gravatar imagevdelecroix ( 2013-06-17 16:19:13 +0200 )edit

Ah, graphics arrays unfortunately don't behave well with respect to different options for each array (yet). and its friends are the relevant tickets.

kcrisman gravatar imagekcrisman ( 2013-06-18 01:36:06 +0200 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools


Asked: 2013-06-17 10:31:08 +0200

Seen: 319 times

Last updated: Jun 17 '13