Next: , Previous: , Up: Internal Routines   [Contents][Index]


15.5.120 cspline_find

cspline_find( y, levels, [axis=axis, index=index])

Locates (using natural cubic splines) coordinates at which certain values are attained. y contains the data values. levels contains the data levels to search for. axis (a scalar) contains the axis along which to search for the data levels, and defaults to 0.

If no locations are found for any of the levels, then scalar -1 is returned. Otherwise, a two-dimensional array is returned with its 1st dimension equal to the number of dimensions of y and its 2nd dimension equal to the number of found locations. If the result is stored in z, then z(*,i) contain the coordinates of the ith location. The locations are in order of the sought data levels (i.e., first the locations for levels(0), then those for levels(1), and so on), and secondarily in order of the coordinates.

If index is defined, then it is changed to an integer array containing the 2nd coordinate of the result where the locations for each next value from levels begin. If these indices are stored in i, then the locations for levels(j) are z(*,i(j)) through z(*,i(j+1)-1).