Chandra X-Ray Observatory (CXC)
Skip to the navigation links
Last modified: 27 November 2012

How do I change the appearance/location of the axis ticklabels?


Note: the axis ticklabel refers to the (normally) numeric labels drawn at the major tick marks on an axis.

The axis ticklabel attributes control the appearance of the labels drawn at the major tick marks, apart from the format, which is discussed in the How do I change the format of the axis ticklabels? entry.

chips> get_xaxis().ticklabel
         
angle = 0.0
color = default
font = helvetica
fontstyle = normal
halign = -99.0
offset = 6
size = 12
style = outside
valign = -99.0
visible = True

Here we use the commands to change the size, color, and position of the ticklabels:

[The x axis ticklabels are blue whilst the y axis are rotated to be parallel with the axis]
chips> add_curve([1, 5, 10], [4.1e3, 9.5e3, 140.2e3], ["line.style", "noline"])
chips> log_scale(Y_AXIS)
chips> opts = get_xaxis()
chips> opts.ticklabel.size = 18
chips> opts.ticklabel.color = "blue"
chips> opts.ticklabel.offset = 10
chips> set_xaxis(opts)
chips> set_yaxis(["ticklabel.angle", 90, "ticklabel.offset", 15, "ticklabel.halign", 0.5, "ticklabel.size", 18])

The ChIPS GUI

The ChIPS GUI makes it easy to modify a visualization using your mouse, rather than Pythoon functions. New in CIAO 4.5 is the ability to add annotations - such as labels, lines, points and regions - directly from the GUI.



Last modified: 27 November 2012
CXC logo

The Chandra X-Ray Center (CXC) is operated for NASA by the Smithsonian Astrophysical Observatory. 60 Garden Street, Cambridge, MA 02138 USA.   Email: cxcweb@head.cfa.harvard.edu Smithsonian Institution, Copyright © 1998-2012. All rights reserved.