template<typename Numeric>
class npstat::BoxNDScanner< Numeric >
A class for iterating over all coordinates in a multidimensional box (but not a full-fledeged iterator). The expected usage pattern is as follows:
double* coords = ... (the buffer size should be at least box.dim())
for (BoxNDScanner<double> scan(box,shape); scan.isValid(); ++scan)
{
scan.getCoords(coords, coordsBufferSize);
.... Do what is necessary with coordinates ....
.... Extract linear bin number: ..............
scan.state();
}
The coordinates will be in the middle of the bins (imagine a multivariate histogram with boundaries defined by the given box).