Last modified: December 2013

URL: https://cxc.cfa.harvard.edu/chips/ahelp/current_image.html
Jump to: Description · Examples · Bugs · See Also


AHELP for CIAO 4.11 ChIPS v1

current_image

Context: images

Synopsis

Set the specified image as current.

Syntax

current_image(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_image command sets the image indicated by the argument as the current image; 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.


Examples

Example 1

chips> id = ChipsId()
chips> add_image('image.fits','id=events')
chips> add_image('image2.fits')
chips> id.image = "events"
chips> hide_image(id)
chips> current_image(id)

Two images are created; the second image is current after it is created. The id.image command sets the image value of the ChipsId structure to the first image, then the current_image command makes that image current.

The output of info_current for this session is:

chips> print(info_current())
Window [win1]
  Frame [frm1]
    Plot [plot1]
      X Axis [ax1]
      Y Axis [ay1]
      Image [events]
    Coord Sys [Data]
    Coord Sys ID [plot1_ax1ay1]

Example 2

chips> add_image('evt2_image.fits','id=events')
chips> add_image('evt2_image2.fits')
chips> current_image("events")

Two images are created. After the second image is created, it is current. The current_image command then sets the first image as the current image.


Bugs

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

See Also

concepts
chipsid, currency
contrib
chips_helix, imextent
images
add_image, delete_image, display_image, get_image, hide_image, load_colormap, print_image, remove_image_channel, set_image, shuffle_image