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/min.tm.html
Hardcopy (PDF): A4 | Letter
AHELP for CIAO 3.4 min Context: slangrtl

Synopsis

Get the minimum value of an array

Syntax

result = min (Array_Type a [,Int_Type dim])

Description

The min function examines the elements of a numeric array and returns the value of the smallest element. If a second argument is given, then it specifies the dimension of the array to be searched. In this case, an array of dimension one less than that of the input array will be returned with the corresponding elements in the specified dimension replaced by the minimum value in that dimension.

Example

Consider the 2-d array

      1       2       3       4       5
      6       7       8       9       10

generated by

      a = _reshape ([1:10], [2, 5]);

Then min(a) will return 1, and min(a,0) will return a 1-d array with elements

      1        2       3       4       5
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.