Description Usage Arguments Note See Also Examples
View source: R/closest_atlas_regions.R
Finds the closest atlas regions according to the brain surface parcellation 'brainparc' for the given query vertex coordinates. The coordinates must be in the surface space of the surface included in the 'brainparc'.
1 2 3 4 5 6 7 8 | coord_closest_regions(
brainparc,
coordinate,
linkage = "single",
distance = "euclidean",
silent = getOption("brainloc.silent", default = FALSE),
num_regions_to_report = 5L
)
|
brainparc |
a brain parcellation, see functions like |
coordinate |
|
linkage |
character string, one of |
distance |
character string, one of |
silent |
logical, whether to suppress console messages. |
num_regions_to_report |
scalar integer, the number of closest regions to report (will be reported in increasing order, by distance). Pass |
This is a wrapper around vertex_closest_regions
. It first computes the surface vertex closest to the given coordinate (using coord_closest_vertex
), then runs vertex_closest_regions
with that vertices coordinates.
vertex_closest_regions
is faster if you have a vertex index for the surface in 'brainparc' instead of a coordinate.
1 2 3 4 5 | ## Not run:
bp = brainparc_fs(fsbrain::fsaverage.path(), "fsaverage", atlas="aparc");
coord_closest_regions(bp, bp$surfaces$white$lh$vertices[1:3,]);
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.