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 2006

URL: http://cxc.harvard.edu/ciao3.4/chips_split.html
Hardcopy (PDF): A4 | Letter
AHELP for CIAO 3.4 chips_split Context: chips

Synopsis

Creates multiple drawing areas.

Syntax

Integer_Type chips_split(numXpanes,numYpanes[,whichPane])

Description

This is a S-Lang version of the ChIPS SPLIT command. It creates multiple drawing areas (also called panes), optionally selecting which one is to be the "current" one ("whichPane"). The command splits the display up into "numXpanes" by "numYpanes" drawing areas. These areas (or panes) are numbered sequentially from the upper-left, going down the rows, so

  chips> chips_split( 2, 3, 3 )
  6
  chips> chips_line( 0, 0, 1, 1 )
  0
      

splits the display into 2 columns of three rows and sets the current pane to be the bottom-left one (number 3). A line is then drawn in this pane.

The function returns the number of panes actually created.

Arguments for chips_split

Name Type Default Comment
numXpanes Integer_Type number of columns
numYpanes Integer_Type number of rows
whichPane Integer_Type 1

The routine prints a usage message if used with the wrong number of arguments:

  chips> chips_split(1)
  Usage: chips_split(nx,ny[,drawing_area_selected])
  chips_split(1);

Example 1

  chips> chips_split(1,2)
  2
  chips> split gap 0.1
	

Here we mix ChIPS and S-Lang commands. The chips_split() call creates two drawing areas, stacked vertically. We then use a ChIPS SPLIT command to add a gap between the two panes.

Example 2

  () = chips_split(1,2);
  () = chips_eval( "split gap 0.1" );
	

This is a S-Lang version of the previous example.

Example 3

  chips_clear;
  () = chips_split(2,2,3);
  () = chips_label(0.5,0.5,"Pane: 3");
	

This set of commands will clear the screen, create 4 drawing areas (ina 2 by 2 grid) and add the text "Pane: 3" to the third (top right) one.

Bugs

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

Hardcopy (PDF): A4 | Letter
Last modified: December 2006



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.