Description Usage Arguments Value Examples
Generate array annotation boundary segments for ggplot2
1 | aba_slice_anno_boundaries(anno, slice_num, plane = "coronal")
|
anno |
A 3-d annotation array like that generated by aba_get_annotation_array() |
slice_num |
A number indicating which slice to use. |
plane |
Which plane to return. Options are "coronal", "saggital", and "horizontal". Default is "coronal" |
a data.frame of segment coordinates with x, xend, y, and yend.
1 2 3 4 5 6 7 8 9 10 11 12 13 | library(dplyr)
library(ggplot2)
boundary_df <- aba_get_annotation_array() %>%
aba_symmetrize_matrix("min") %>%
aba_melt_3d("atlas_id") %>%
filter(atlas_id != 0) %>%
aba_slice_anno_boundaries(30, "coronal")
ggplot(boundary_df) +
geom_segment(aes(x = x, xend = xend,
y = y, yend = yend)) +
scale_y_reverse()
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.