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/adjust_grid_xrelsize.py.html
AHELP for ChIPS 4.0 adjust_grid_xrelsize Context: py.chips

Synopsis

Modifies the widths of one column of plots created by split or grid_objects.

Syntax

adjust_grid_xrelsize([id,] column, size)

Description

  • id - an optional ChipsId structure containing values to modify the currency state for the command.
  • column - which column of plots to modify. The columns are numbered from left to right, starting at 1.
  • size - ratio of the width of the selected column to the other columns (e.g. 1=same size, 2=twice as wide, .5=half as wide).

The adjust_grid_xrelsize command the size of a column of plots relative to the other columns in the frame created by split or grid_objects.

The width of the specified column is set to "size * unit_width". All other columns are set to unit_width.

The following is used to determine the widths of the columns:

available_area = 1 - (left_margin + right_margin + (num_cols -1)*xgapsize)

unit_width = available_area / ((num_cols-1) + size)

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

Example 1

chips> split(3,3)
chips> adjust_grid_xrelsize(2,2)

A split command is issued to create a grid of 9 plots. The adjust_grid_xrelsize command sets the center column to be twice as wide as the other columns.

Example 2

chips> grid_objects(2,2,.05,.05,1)
chips> adjust_grid_xrelsize(1,.5)

A grid_objects command is called to create a grid of 4 plot areas. The adjust_grid_xrelsize command makes the first column half as wide as the second column.

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.