Getting Started Documentation Glish Learn More Programming Contact Us
Version 1.9 Build 1556
News FAQ
Search Home


next up previous contents index
Next: componentlist.is_physical - Function Up: componentlist - Tool Previous: componentlist.indices - Function


componentlist.sort - Function



Package synthesis
Module componentmodels
Tool componentlist


Sort the components in a list


Synopsis
sort(criteria, log)


Description
The sort function can sort all the components in a list using a variety of criteria. Currently the following criteria are available.
Flux
Sorts the list so that the brightest components, as defined by the abs(I), are at the beginning of the list.
Position
Sorts the list so that components that are closest to a reference position, which is currently fixed at (ra,dec) = (0, 0), are at the beginning of the list.
Polarization
Sorts the list so that components with the largest fractional polarization, $ {\frac{\sqrt{Q^2+U^2+V^2}}{I}}$, are at the front of the list. Components where I = 0 are placed at the end of the list.
The parsing of the string containg the sorting criteria is case insensitive. You cannot sort a list that has been opened read only.


Arguments

criteria a string containg the criteria to use to sort the list
Allowed: 'Flux', 'Position' or 'Polarization'
Default: Flux
log Send a message to the logger
Allowed: Boolean
Default: T


Returns
nothing


Example
      include 'componentlist.g'
      cl := componentlist('crux.cl');
      cl.sort('Polarization');
This example reads a componentlist from disk and then proceeds to sort the components so that the most polarized components are at the front of the list.



next up previous contents index
Next: componentlist.is_physical - Function Up: componentlist - Tool Previous: componentlist.indices - Function   Contents   Index
Please send questions or comments about AIPS++ to aips2-request@nrao.edu.
Copyright © 1995-2000 Associated Universities Inc., Washington, D.C.

Return to AIPS++ Home Page
2006-10-15