Chandra X-Ray Observatory
	(CXC)
Skip to the navigation links
Last modified: December 2013

URL: http://cxc.harvard.edu/chips/ahelp/current_curve.html
Jump to: Description · Examples · Bugs · See Also


AHELP for CIAO 4.6 ChIPS v1

current_curve

Context: curves

Synopsis

Set the specified curve as current.

Syntax

current_curve(id)

Description

The function arguments.

Argument Description
id A ChipsId structure identifying the item, or a string containing the name of the object.

The current_curve command sets the curve indicated by the argument as the current curve; see "ahelp currency" for general information on currency.

Use the info_current command to retrieve a list of all the current items in the ChIPS session, as shown below.

Example 1

chisp> id = ChipsId()
chisp> add_curve([-4,0,4], [0,5,10])
chisp> x = np.arange(-4, 4)
chisp> add_curve(x, x*x, "id=parabola")
chisp> id.curve = "crv1"
chisp> current_curve(id)

Two curves are created; the second curve is current after it is created. The id.curve command sets the curve value of the ChipsId structure to the first curve, which has the id "crv1" by default. The current_curve command makes that curve current.

The output of info_current for this session is:

chisp> print(info_current())
Window [win1]
  Frame [frm1]
    Plot [plot1]
        X Axis [ax1]
        Y Axis [ay1]
        Curve [crv1]
   Coord Sys [Data]
   Coord Sys ID [plot1_ax1ay1]

Example 2

chisp> add_curve([-4,0,4], [0,5,10], "id=diag")
chisp> x = np.arange(-4, 4)
chisp> add_curve(x, x*x, "id=parabola")
chisp> current_curve("diag")

Two curves are created. After the second curve is created, it is current. The current_curve command then sets the first curve as the current curve.

Example 3

chisp> add_curve([-23,4,15], [10,8,11])
chisp> add_curve([-4,0,4], [0,5,10])
chisp> current_curve("all")
chisp> set_curve({'symbol.style': 'none'})

Two curves are created. After the second curve is created, it is current. The current_curve command then makes all curves current.

Bugs

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

See Also

chips
make_figure
concepts
chipsid, currency
curves
add_curve, delete_curve, display_curve, get_curve, hide_curve, set_curve, shuffle_curve

Last modified: December 2013
Smithsonian Institute Smithsonian Institute

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-2014. All rights reserved.