inside_neuropils: Calculate the cable length inside of different neuropils in a...

View source: R/inside_neuropils.R

inside_neuropilsR Documentation

Calculate the cable length inside of different neuropils in a segmented .surf brain

Description

Calculates the cable length supplied by neurons 'x' to different brain regions defined in 'brain'.

Usage

inside_neuropils(
  x,
  brain,
  method = c("cable", "PRE", "POST"),
  min.endpoints = 1,
  alpha = NULL,
  ...
)

## S3 method for class 'neuron'
inside_neuropils(
  x,
  brain,
  method = c("cable", "PRE", "POST"),
  min.endpoints = 1,
  alpha = NULL,
  ...
)

## S3 method for class 'neuronlist'
inside_neuropils(
  x,
  brain,
  method = c("cable", "PRE", "POST"),
  min.endpoints = 1,
  alpha = NULL,
  ...
)

points_in_neuropil(x, brain, alpha = NULL, ...)

in_neuropil(
  x,
  brain,
  neuropil,
  method = c("cable", "PRE", "POST"),
  min.endpoints = 1,
  alpha = NULL,
  ...
)

## S3 method for class 'neuron'
in_neuropil(
  x,
  brain,
  neuropil,
  method = c("cable", "PRE", "POST"),
  min.endpoints = 1,
  alpha = NULL,
  ...
)

## S3 method for class 'neuronlist'
in_neuropil(
  x,
  brain = nat.flybrains::FCWBNP.surf,
  neuropil = "LH_R",
  method = c("cable", "PRE", "POST"),
  min.endpoints = 1,
  alpha = NULL,
  ...
)

Arguments

x

a set of neurons or, for points_in_neuropil a mxn matrix of 3D points

brain

the .surf brainspace in which the neurons are registered, must be segmented into neuropils

method

whether to calculate cable inside a given neuropil volume, or synapse number (PRE or POST)

min.endpoints

the minimum number of endpoints a neuron must have in a neuropil to be counted as included in it

alpha

the alpha given to the ashape3d() function to generate neuropil objects by which to calculate point inclusion. If NULL then nat::pointsinside is used.

...

additional arguments passed to methods

neuropil

the code for the neuropil volume to be searched.

Value

a matrix of 3D points


alexanderbates/catnat documentation built on Sept. 5, 2023, 4:51 a.m.