PML Customisation User Guide

Arrays : Sorting Arrays Using Array Methods
The sort is into ascending order and will be an ASCII sort on an array of STRING elements and a NUMERIC sort on an array of REAL values.
The Sort() method returns the array itself as a list result, so it is possible to follow the call to the Sort() method immediately with a call to the Invert() method, which will return a descending sort:
An alternative approach is an indirect sort using the method SortedIndices() which returns a REAL array representing new index positions for the array elements in their sorted positions:
More important, the index values in !NewPositions can be used to sort other arrays as well.
Would create a new array !index representing the subscript values of the array elements in !Animals then sort these index values (without altering the array !Animals). After the sort, !index would look like this:
Would result in !index now looking like:

1974 to current year. AVEVA Solutions Limited and its subsidiaries. All rights reserved.
AVEVA Logo