arrop

The arrop Statement

The arrop statement lets you perform several different operations on an array containing numeric values. The operations are OPARR_SUM, OPARR_MEAN, OPARR_SUMSQR, OPARR_STD, OPARR_MIN, OPARR_MAX, and OPARR_SORT.

In the case of OPARR_SORT the output parameter should be an array of the same type as the input array. In all the other cases it can be any scalar type large enough to hold the resulting value. If the data in the array is of the float type then the output should also be of the float type.

The fourth and fifth arguments indicate the starting element and the number of elements to operate on. To use the entire input array you simply pass the NA constant in as the value for start and length. The syntax of the arrop statement is shown below.

 // execute an array operation
 // arrop op, dest, src, start, len
 arrop OPARR_SUM, sum, data, NA, NA
 arrop OPARR_SORT, data2, data, NA, NA

Generated by  doxygen 1.6.2