naginterfaces.library.fit.dim2_​spline_​sort

naginterfaces.library.fit.dim2_spline_sort(lamda, mu, x, y)[source]

dim2_spline_sort sorts two-dimensional data into rectangular panels.

For full information please refer to the NAG Library document for e02za

https://support.nag.com/numeric/nl/nagdoc_30/flhtml/e02/e02zaf.html

Parameters
lamdafloat, array-like, shape

to must contain, in nondecreasing order, the intercepts on the axis of the sides of the panels parallel to the axis.

mufloat, array-like, shape

to must contain, in nondecreasing order, the intercepts on the axis of the sides of the panels parallel to the axis.

xfloat, array-like, shape

The coordinates of the th data point , for .

yfloat, array-like, shape

The coordinates of the th data point , for .

Returns
pointint, ndarray, shape

For , is the index of the first point in panel , is the index of the second point in panel and so on.

indicates that was the last point in the panel.

The coordinates of points in panel can be accessed in turn by means of the following instructions:

i_n = point[m+i-1]
while i_n != 0:
    xi = x[i_n-1]
    yi = y[i_n-1]
    .
    .
    .
    i_n = point[i_n]
...
Raises
NagValueError
(errno )

On entry, , and .

Constraint: .

(errno )

On entry, , and .

Constraint: .

(errno )

On entry, , , and .

Constraint: .

(errno )

On entry, .

Constraint: .

(errno )

On entry, .

Constraint: .

(errno )

On entry, .

Constraint: .

Notes

A set of data points with rectangular Cartesian coordinates are sorted into panels defined by lines parallel to the and axes. The intercepts of these lines on the and axes are given in , for and , for , respectively. The function orders the data so that all points in a panel occur before data in succeeding panels, where the panels are numbered from bottom to top and then left to right, with the usual arrangement of axes, as shown in the diagram. Within a panel the points maintain their original order.

[figure omitted]

A data point lying exactly on one or more panel sides is taken to be in the highest-numbered panel adjacent to the point. The function does not physically rearrange the data, but provides the array which contains a linked list for each panel, pointing to the data in that panel. The total number of panels is .