Last chance! 50% off unlimited learning
Sale ends in
Find the shortest distance between each point in one data set and the points in a second set.
This function determines the distance between every point in data set 1 and the points in data set 2. Unlike this function's naive counterpart, find_min_dists, this function divides the PALM/iPALM localization data into blocks, operates on the data in each block, and then performs linking operations on neighboring blocks.
.find_min_dists_cpp(mOne, mTwo)
A numeric matrix where each row is a localization and each column is a spatial axis.
A numeric matrix with the same number of columns as mOne.
# NOT RUN {
set.seed(10)
mOne <- as.matrix(data.frame(
x = rnorm(10),
y = rbinom(10, 100, 0.5),
z = runif(10)
))
mTwo <- as.matrix(data.frame(
x = rnorm(20),
y = rbinom(20, 100, 0.5),
z = runif(20)
))
.find_min_dists_cpp(mOne, mTwo)
# }
# NOT RUN {
# }
Run the code above in your browser using DataLab