create_binning_func: Returns a function which gives C++ array indices.

Description Usage Arguments Details Value

View source: R/radius.r

Description

Big fat warning: binning_func returns indices for C++ array indexing. Indexing starts from zero in C++. If you need to use the result of binning_func() in R, add + 1L to the result.

Usage

1

Arguments

r_vec

The radius vector which defines the endpoints of the bins.

Details

The bins are exclusive from left and inclusive from right.

If the first r_vec value is zero, the index for that "bin" matching the r-interval [0, 0] should never be given by the returned function.

Also varying step size in r_vec is handled correctly.

Value

A function that turns the distance between a pair of points into a bin index.


myllym/marksummary documentation built on May 23, 2019, 11:59 a.m.