About Chandra Archive Proposer Instruments & Calibration Newsletters Data Analysis HelpDesk Calibration Database NASA Archives & Centers Chandra Science Links

Skip the navigation links
Last modified: December 2007

URL: http://cxc.harvard.edu/chips4.0/set_contour.sl.html
AHELP for ChIPS 4.0 set_contour Context: sl.chips

Synopsis

Modifies the attributes of an existing contour.

Syntax

set_contour([id,] values);

Description

  • id - an optional ChipsId structure containing values to modify the currency state for the command or a string id to modify a contour within the current plot.
  • values - a list containing attribute value pairs or a ChipsContour object.

The set_contour command sets the specified attributes to the provided values. The modified contour becomes current. Multiple contours may be modified with a single command by setting the currency to "all".

Customizing the Contour

There are several attributes that control the characteristics of contours. The set_contour command may be used to modify the attribute values of an existing contour at any time during a ChIPS session. See "ahelp sl.chips attributes" and "ahelp sl.chips setget" for more general information.

If multiple attributes are being set simultaneously and one of them fails, the entire command will fail and the contour will not be modified.

The attributes associated with contours are:

Attribute Description Options Default
algorithm algorithm used to calculate contours chips_standard|chips_marching chips_standard
color Color of the contours see the Color section of "ahelp sl.chips chipsopt" default
depth Integer value indicating line depth see the Depth section of "ahelp sl.chips chipsopt" 100
interval distance between contours when mode is interval positive floating point value 10.0
levels number of contour levels when mode is count positive integer value 5
mode Mode used to determine the contour levels see the Contour Mode section of "ahelp sl.chips chipsopt" nice
style the pattern used for the contour style see the Line Style section of "ahelp sl.chips chipsopt" chips_solid
thickness Thickness of the contour 0.5:9 1

These individual commands are also available for setting attribute values:

set_contour_algorithm
set_contour_color
set_contour_depth
set_contour_interval
set_contour_levels
set_contour_mode
set_contour_numlevels
set_contour_style
set_contour_thickness
set_contour_transform

Setting the Contour Transform

The transform used to create contours is not controlled by an attribute of the set_contour command. It is specified with set_contour_transform.

The command sets the transform to contour for future use and applys the transform to the contour. Contours currently only support a single transform. Multiple calls to this function will cause the transform already associated with the contour to be dropped and the the new transform to be set and applied. Passing "NULL" will cause the transform associated with the contour to be dropped.

Example 1

chips> set_contour({"interval",5,"color","peach"});

Using attribute/value pairs, set the contour to display using an interval of 5 and with the color peach.

Example 2

chips> settings = ChipsContour;
chips> settings.color = "red";
chips> settings.style = "shortdash";
chips> set_contour("ctr1",settings);

Populate the "settings" structure with attribute values, then use it to set ctr1 to be a red, short-dashed contour.

Example 3

chips>a =struct {thickness, color};
chips>a.thickness=2,a.color="salmon";
chips>set_contour(a);

Create a user-defined structure with thickness and color fields. Use the structure to modify the values of the current contour.

Bugs

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

Last modified: December 2007



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.