Add volumes to an anatomical hierarchy
Source:R/minc_hierarchical_anatomy.R
addVolumesToHierarchy.RdTakes a tree of anatomical hierarchies and adds volumes from anatGetAll
Details
Each node in the tree has two new attributes:
volumes - The matrix of volumes
meanVolume - The mean of the volumes of that node
Currently propagates volumes up the tree by summing. Future versions will add propagating through weighted means or other functions
Examples
if (FALSE) { # \dontrun{
abijson <- "allen.json"
defs <- "Dorr_2008_Steadman_2013_Ullmann_2013_mapping_of_labels.csv"
hdefs <- makeMICeDefsHierachical(defs, abijson)
allvols <- anatGetAll(gf$filenames)
hanat <- addVolumesToHierarchy(hdefs, allvols)
} # }