| Version 1.9 Build 1556
|
|
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,
, 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 |