group_events {LOMAR} | R Documentation |
group_events
Description
Localisation events are grouped by recursively clustering mutual nearest neighbours. Neighbours are determined using the Mahalanobis distance to account for anisotropy in the localisation precision. Since the Mahalanobis distance has approximately a chi-squared distribution, a distance threshold can be chosen from a chi-squared table where the number of degrees of freedom is the dimension and alpha can be seen as the probability of missing a localization event generated from the same fluorophore as the event under consideration.
Usage
group_events(points, locprec = NULL, locprecz = NULL, p = 0.1)
Arguments
points |
a data frame with columns x,y,z. |
locprec |
localization precision in x,y |
locprecz |
localization precision along z, defaults to locprec |
p |
confidence level, see description. Defaults to 0.1 |
Value
a list with two elements:
points: a point set as data frame with columns x,y,z
membership: a vector of integers indicating the cluster to which each input point is allocated.