Last modified: December 2013

URL: https://cxc.cfa.harvard.edu/chips/ahelp/get_point.html
AHELP for CIAO 4.11 ChIPS v1

get_point

Context: points

Synopsis

Retrieves the attribute value(s) of the point.

Syntax

get_point()
get_point(id)
get_point(id, attribute)

Description

The function arguments.

Argument Description
id A ChipsId structure identifying the item, or a string containing the name of the object.
attribute The name of the attribute to retrieve, such as 'style' or 'color'.

The get_point command returns a structure containing all the attribute values of the point. 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.

Please see the section "Point Preferences and Attributes" below the examples for a list of the point attributes.

To see if a point is hidden or visible, use the get_point_visible command.

Advanced Functions

The module of advanced ChIPS functions contains other commands for retrieving attribute values (refer to "ahelp chips" for information on loading the module):

get_point_angle
get_point_color
get_point_depth
get_point_fill
get_point_size
get_point_style

Examples

Example 1

chips> add_point(.1, .1, "style=diamond")
chips> print(get_point())
chips> print(get_point("pnt1", "style"))

A point is created and becomes current. Calling get_point with no argument returns all the attributes of the object. get_point is called a second time to return just the "style" attribute.

Example 2

chips> add_point(.1, .1, "style=diamond")
chips> add_point(.2, .2, "style=cross")
chips> print(get_point("pnt1"))

Two points are created. get_point is called with the id of the first point, returning all attributes.

Example 3

chips> id=ChipsId()
chips> id.point = "pnt1"
chips> print(get_point(id))

A ChipsId structure is created and the id.point field is set to "pnt1". get_point is called with the ChipsId.

Example 4

chips> pi = get_point()
chips> print(pi)

Retrieve a structure containing the attribute values of the current point and store the results in "pi". Print the contents of "pi".


Point Preferences and Attributes

The attributes associated with points are given in the following table, where the "Set?" column refers to whether the attribute can be changed using the set_point() command. To change the point preference settings prepend "point." to the attribute name.

Attribute Description Options Default Set?
angle Angle, in degrees, at which the point is drawn -360.0 to 360.0 0.0 Yes
color color of the point name or hex; see the Color section of "ahelp chipsopt" default Yes
coordsys coordinate system for the point PIXEL, WINDOW_NORM, FRAME_NORM, PLOT_NORM, DATA see "ahelp coordsys" Yes
depth Integer value indicating point depth see the Depth section of "ahelp chipsopt" default Yes
fill fill the point? see the Booleans section of "ahelp chipsopt" true Yes
size size of the point 1 to 100 12 Yes
stem stem used for point id An alpha-numeric character sequence that does not contain a space pnt No
style symbol style see the Symbol Styles section of "ahelp chipsopt" cross Yes

Bugs

See the bugs pages on the ChIPS website for an up-to-date listing of known bugs.

See Also

concepts
setget
points
add_point, current_point, delete_point, display_point, hide_point, move_point, set_point, shuffle_point
utilities
set_current