overlap_score: Generate a connectivity matrix based on euclidean distance...

View source: R/morphometry.R

overlap_scoreR Documentation

Generate a connectivity matrix based on euclidean distance between points

Description

Generates an 'overlap matrix' of overlap scores between neurons in the outputneurons and inputneurons pools. For every point in a given neuron in outputneurons, a distance score is calculated to every point in a neuron in inputneurons. The sum of this score is added to the final output matrix. The score is calculated as e(-d^2/(2*delta^2)), where d is the euclidean distance between the two points, and delta is the expected distance in um that is considered 'close'. It is recommended that the user resamples neurons before use, using resample.

Usage

overlap_score(outputneurons, inputneurons, delta = 1, progress = TRUE)

Arguments

outputneurons

first set of neurons

inputneurons

second set of neurons

delta

the distance (in um) at which a synapse might occur

progress

whether or not to have a progress bar

Value

a matrix of overlap scores

See Also

potential_synapses, resample

Examples

## Not run:  
# Calculate how much some neurons overlap with one another
## Example requires the package nat.flybrains
Cell07PNs_overlap = overlap_score(outputneurons = Cell07PNs, inputneurons = Cell07PNs)

## Plot the results
heatmap(Cell07PNs_overlap)

## End(Not run) 

natverse/nat documentation built on Feb. 19, 2024, 7:19 a.m.