Grid Controls


A Grid Control displays data as a table of columns and rows. When measurements are displayed in a grid control, one row of the grid contains one measurement. Grid controls are displayed in Measurement Panes and Report Windows. The Statistics Report Window and Apphot measurement pane shown below both contain grid controls. The report window is a separate, top level window whereas the measurement pane is a window owned by a top-level window. Several common tools, such as Scatter Plot, are available for all grid controls.

statisticsreport.png

Grid Controls are used by the following features. Some grids are displayed in a Report Window and others are displayed in a Measurement Pane:

Grid controls are used by the following windows:

Aperture Photometry

Astrometric Calibration

Centroid Measurements

Pixel Value Editor

Statistics Measurements

FITS Header Pane

Distance Measurements

Image Cursor

Selecting Grid Cells

Various commands that work with the grid data, such as Copy andScatter Plot, can use the entire table or use data only in specific cells of the grid. To work with specific cells, those cells must be "selected". A grid cell is "selected" when it is marked, or highlighted. Marking cells in a table works essentially the same way you select files from the Open dialog or you select cells in Microsoft Excel. Cell selection is started by pressing the left mouse button down on the starting cell, then you drag to the last cell in the block. However, there are some variations on this basic theme which add capability to commands that work with table data.

The pull-down View menu for Report Windows and the Grid Command Menu both contain a popup menu named Selection Mode. TheSelection Mode provides 3 modes of selection for marking cells:

The Multiple and Row modes allow more than one cell to be selected at one time. The basic procedure for marking multiple cells involves pressing the left button down on the first cell (left button down and hold), then dragging the mouse to the final cell.

Using the [Ctrl] Key to Mark Blocks

You can also add cells that are not touching a marked block by using the Windows standard[Ctrl] key modifier. Here are the rules for marking multiple cells in Multiple Mode or Row Mode:

  1. To mark a block of cells, mouse down on the starting cell, then drag the mouse to the final cell. Release the mouse button at the final cell

  2. To begin marking an additional block of cells, press the[Ctrl] key before pressing the left mouse button down on the starting cell. With[Ctrl] pressed, click on the starting cell and repeat step (1).

  3. Repeat step (2) to mark each additional block.

Using these rules, you can mark any group of cells in the table. For example, the picture below shows a Statistics Report with 3 blocks selected using these rules:

Here is the recipe for marking 3 rows of cells as shown in the picture above:

  1. Right click on the report table to open the Grid Command Menu. Select Selection Mode > Multiple.

  2. Mouse-down on "130.363894" and drag right to "10.6911024". Release the mouse to mark the first block.

  3. Press and hold [Ctrl]. Then mouse-down on "128.924858" and drag downward and to the right to "9.51408486". Release the mouse to mark the second block.

If you were to use the Copy command in the menu, only these 2 groups of cells would be copied to the Windows clipboard.

Marking Rows

Marking rows works the same as for marking cells in Multiple Selection Mode, except that clicking anywhere in a row marks the entire row. Dragging the mouse inRow Selection Mode marks a block of rows. You can mark separate blocks of rows using the[Ctrl] key as described above.

Note

To use the Scatter Plot command to plot specific rows of data, you must use Row Selection Mode, not Multiple Selection Mode to mark the target rows.

Arranging Grid Data

Each Measurement Pane or Report Window provides some functionality to adjust its contents for display purposes. You can sort the rows by any column and you can reorder the columns so that certain quantities become adjacent to each other. These adjustments can be combined with the copy, save, or print commands to select particular data from the table. See the Tutorial: Working with Measurements in a Grid.

Operation

Procedure

Resizing a Column

Mouse down on the column separator line and drag the separator until the column is the desired width. Release the mouse at the final size.

Sorting Rows by values in a column

Click on the column header to to perform the sort. A sorting triangle then appears inside the column label. Click again to reverse the sort order.

Reordering Columns

Mouse down on the column header away from the separator. Drag the mouse pointer outside the cell and the left column separator will appear in bold. Drag the separator to the insertion point and release the mouse. The column of data will move to the insertion point.

Editing Data

Click on the cell you wish to edit and the cell will highlight to show that edit mode is enabled. After changing the text, save your changes by either clicking outside the cell or moving outside the cell using the keyboard arrow keys.

Creating a Scatter Plot

Use the Scatter Plot command to plot data in one report column against data in another column.

The Grid Command Menu

The Grid Command Menu provides commands for working with the data in the grid control. To open the Grid Command Menu, right click on the grid.

Exporting Grid Data

Usually you will want to copy or otherwise export measurements from the Grid Control into other software or send it to permanent storage. In the example below, we use the tabular data for Statistics. To copy the entire grid, use the Copy All command in the Grid Command Menu. To work with only a range of cells, follow the procedure described below.

When measuring statistics, you get a table with various quantities listed in its 9 columns and several rows. Suppose you only want to save the Mean, Median,Std Dev, Minimum, and Maximum values. Then you need to select only these cells from the table. To extract these cells, right-click on the grid to open the Grid Command Menu. For a Measurement Pane, you also can use the menu (triangle) button on the pane's title bar. In the Grid Command Menu, be sure that the Selection Mode is set to use the entire grid or just the selected cells or rows (if not, change the setting in the menu) as shown below

Next, point the mouse at the top left cell of interest, drag the mouse to the lower right cell of interest, and release the mouse button. A region selected in this way is shown in the figure below.

With the target cells highlighted, right click on the table to open the Grid Command Menu. As shown below, click the Copy Selection item to copy the selected cells to the Windows clipboard. Note: If only a single cell is selected, this command appears simply as Copy.

To complete the operation, activate the software where you wish to paste these cells and use the Edit > Paste command (or similar procedure) to transfer the data into the target software.

Related Topics

Measurement Panes, Report Windows, Grid Properties dialog, Grid Command Menu, Scatter Plot