Colocalization._haussdorff_distanceMethod
haussdorff_distance(xs, ys, aggregate=maximum)

Returns, for two segmented masks, the Haussdorff distance (per object).

Agg=maximum is the default, returns the maximum symmetric Euclidean distance of X to Y
Colocalization.colocalize_2dMethod
colocalize(xs, ys; metric="pearson", windowsize=3)

Compute a colocalization metric `metric` on a window size of `windowsize^2`.

Set `windowsize` to >= 3, odd. If set to -1, use the entire image, output will be single scalar.

See `metrics` for metrics to use.
Colocalization.colocalize_allMethod
colocalize_all(xs, ys; windowsize=3)

Apply all coloc metrics. Returns a dictionary, so results are stored in results[metric].
Runs multithreaded.
```julia
xs = rand(10, 10)
ys = rand(10, 10)
res =colocalize_all(xs, ys)
correlation_values = res["pearson"]
μ, md, σ, min, max, q1, q3, iqr, q95, q99, nans = describe_map(correlation_values)
```
Colocalization.compute_distances_cc_to_maskMethod
compute_distances_cc_to_mask(from_cc, to_mask)

Compute distances, overlap, and a distance map from a component map to a mask.
The distance map has a token 0.1 if the distance = 0 to prevent occlusion with background.
Colocalization.filter_projectionFunction
filter_projection(image, w=1, z=0)

Compute a 2-stage filtered mask based on image. w is the window size, z is the number of standard deviations to use as a threshold.
This removes isolated localizations of low intensity.
Colocalization.haussdorff_distanceMethod
haussdorff_distance(xs, ys, aggregate=maximum)

Returns, for two segmented masks, the Haussdorff distance (per object).

Agg=maximum is the default, returns the maximum symmetric Euclidean distance of X to Y
Colocalization.haussdorff_maxMethod
haussdorff_max(xs, ys)

The reference implementation for the Haussdorff distance, returns the maximum symmetric Euclidean distance of X to Y
See https://en.wikipedia.org/wiki/Hausdorff_distance
Colocalization.haussdorff_meanMethod
haussdorff_mean(xs, ys)

A variant of the Haussdorff distance, returns the mean symmetric Euclidean distance of X to Y
See https://en.wikipedia.org/wiki/Hausdorff_distance
Colocalization.metrics_iteratorMethod
metrics_iterator()

Returns an iterator over the supported metrics, in String / Function pairs.

Metric functions expect equal shaped array, and return a scalar value
Colocalization.segmentFunction
segment(image, scale=1.0)

Perform basic otsu thresholding. Scale argument allows you to include more (>1) background or less (<1)
Colocalization.spearMethod
spear(left, right)
Return the spearman correlation between arguments, and the significance (z-test, t-test)

Reuse with permission from https://github.com/bencardoen/SubPrecisionContactDetection.jl
Colocalization.union_distance_maskMethod
union_distance_mask(xs, ys, distance)

Finds the connected components in X that are <= distance to any component in Y and vice versa

Returns mask_x, mask_y
Colocalization.union_maskMethod
union_mask(xs, ys)

mask where any component that has a non-zero intersection is set to 1.