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 2008

URL: http://cxc.harvard.edu/chips4.1/adjust_grid_yrelsizes.sl.html
AHELP for ChIPS 4.1

adjust_grid_yrelsizes

Context: sl.chips

Synopsis

Specify the height of all rows of plots created by split or grid_objects.

Syntax

adjust_grid_yrelsizes([id,] heightarray);

Description

  • id - an optional ChipsId structure containing values to modify the currency state for the command.
  • heightarray - an array containing the ratios for each row in order (top to bottom).

The adjust_grid_yrelsizes command changes the size of all rows of plots in a frame created by split or grid_objects, using the values supplied in the "heightarray" parameter. The relational heights of all rows must be specified. For each row i, the height is calculated as "heightarray[i] * unit_height", where

available_area = 1 - (top_margin + bottom_margin + (num_rows-1)*ygapsize)

arraysum = heightarray[0] + heightarray[1] + ..  + heightarray[n]

unit_height = available_area / arraysum

Since the rows are adjusted based on ratios of the heightarrays, the scale of the values is not important. The arrays "[3,6,12]", "[.1,.2,.4]", and "[500,100,200]" all produce the same row height: the rows double in size as they move from top to bottom.

To change the spacing between the plots, use the adjust_grid_gaps command ("ahelp adjust_grid_gaps") .

Example 1

chips> split(3,3);
chips> adjust_grid_yrelsizes([1:3]);

A split command is issued to create a grid of 9 plots. The adjust_grid_yrelsizes command sets the height of the second and third rows of plots to be double and triple the height of the first row, respectively.

Example 2

chips> adjust_grid_yrelsizes({1,1});

Set the heights of two rows of plots to be equal.

Bugs

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

Last modified: December 2008



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.