|
|
|
|
SynopsisRetrieves the attribute value(s) of the axis. Syntaxget_axis() get_axis(id [,attribute]) Description
The get_axis command returns a structure containing all the attribute values of the axis. To retrieve the value of a specific attribute, provide the attribute name and the id or ChipsId of the object. Some values are set to "None" in the returned structure. These entries generally correspond to attributes which may only be modified at creation time, such as the object id. The attributes associated with axes are:
Note that the axis label text is not included in the attributes. In order to get that value, use the get_axis_text command. To see if an axis is hidden or visible, use the get_axis_visible command. Axis RangeThe get_axis_range command returns the range of the specified axis of the current plot. The values are returned as [min, max]. Advanced FunctionsThe module of advanced ChIPS functions contains other commands for retrieving attribute values (refer to "ahelp chips" for information on loading the module): get_axis_automax get_axis_automin get_axis_color get_axis_depth get_axis_label_angle get_axis_label_color get_axis_label_font get_axis_label_fontstyle get_axis_label_halign get_axis_label_size get_axis_label_valign get_axis_label_visible get_axis_major_color get_axis_major_interval get_axis_major_length get_axis_major_mode get_axis_major_num get_axis_major_style get_axis_major_thickness get_axis_majorgrid_color get_axis_majorgrid_style get_axis_majorgrid_thickness get_axis_majorgrid_visible get_axis_minor_color get_axis_minor_interval get_axis_minor_length get_axis_minor_mode get_axis_minor_num get_axis_minor_style get_axis_minor_thickness get_axis_minorgrid_color get_axis_minorgrid_style get_axis_minorgrid_thickness get_axis_minorgrid_visible get_axis_pad get_axis_parallel_offset get_axis_perpendicular_offset get_axis_scale get_axis_thickness get_axis_tickformat get_axis_ticklabel_angle get_axis_ticklabel_color get_axis_ticklabel_font get_axis_ticklabel_fontstyle get_axis_ticklabel_halign get_axis_ticklabel_offset get_axis_ticklabel_size get_axis_ticklabel_style get_axis_ticklabel_valign get_axis_ticklabel_visible get_axis_tickstyle get_axis_transform get_major_ticks_visible get_minor_ticks_visible Example 1
chips> add_axis(X_AXIS, 20, 0, 100, "color=yellow")
chips> print(get_axis())
chips> print(get_axis("ax1","color"))An axis is created and becomes current. Calling get_axis with no argument returns all the attributes of the object. get_axis is called a second time to return just the "color" attribute. Example 2
chips> add_axis(X_AXIS, 20, 0, 100, "color=yellow")
chips> add_axis(XY_AXIS, 40, 0, 100,"color=magenta")
chips> print(get_axis("ax1"))Two axes are created. get_axis is called with the id of the first x-axis, returning all attributes. Example 3chips> id=ChipsId() chips> id.axis="ax1" chips> print(get_axis(id)) A ChipsId structure is created and the id.axis field is set to "ax1". get_axis is called with the ChipsId. Example 4chips> axisatt = get_axis() chips> print(axisatt) Retrieve a structure containing the attribute values of the current axis and store the results in "axisatt". Print the contents of "axisatt". BugsSee the bugs pages on the ChIPS website for an up-to-date listing of known bugs. See Also
|
![]() |
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-2004. All rights reserved. |