Changelog
Source:NEWS.md
neuroatlas 0.1.0.9000
Added
get_hcpex_atlas()andget_atlas("hcpex")for HCPex v1.1: 360 cortical and 66 subcortical regions at 1 or 2 mm in the source-declared MNI152NLin2009cAsym space. Downloads use a pinned upstream revision and checksum-verified caching. Native IDs, abbreviations, full names, colors, hemisphere, and cortical/subcortical membership are available for ROI work; metadata includes citations, license, file receipts, and resampling history.Added a shared, versioned metadata record for atlases and loaded templates:
atlas_metadata(),template_metadata(),atlas_citations(), andtemplate_citations(). Records contain resource identity, actual geometry, role-specific references, file receipts, and structured processing history. Citation access and inspection work offline and survive R serialization.Atlas summaries now consistently display spatial metadata and citation information. Resampled atlases report their actual voxel spacing; original source resolutions remain in artifact records. Grid resampling retains the native anatomical template identity and records the requested grid separately.
Subsetting and dilation preserve metadata and record their parameters. Merges retain both parent records and citations and reject conflicting grids or known template identities. Probability-volume collections and surface template pairs retain their component records.
Missing provenance defaults to uncertain. The bundled ASEG atlas now reports
MNI152_unspecified: header geometry does not verify the precise anatomical template. Olsen’s original atlas publication remains explicitly unverified. See the new “Identify, cite, and trace an atlas” vignette.dilate_atlas()now genuinely honours itsradiusargument. The previous implementation passed a fixedktoRnanoflann::nn(search = "radius"), which returns theknearest neighbours regardless of distance, soradiushad no effect and dilation filled the entire mask (absorbing, for a cortical atlas, distant cerebellar and deep subcortical grey matter). Dilation now uses a standard k-NN search with an explicit Euclidean radius cutoff: in-mask voxels with no parcel withinradiusvoxels are left unassigned. This is a behaviour change — callers that relied on the old whole-mask fill will now get radius-limited results. See the new “Dilating an Atlas to Cover Grey Matter” vignette.Added
get_harvard_oxford_atlas()and registry entries for Harvard-Oxford cortical, subcortical, and combined structural parcellations. The default source is TemplateFlow, with threshold and resolution options for maximum-probabilitydsegimages.Added
get_fsl_atlas()for FSL XML-described atlases, including the documented offset between probabilistic XML label indices and max-probability summary image label values. Added a thin FSL-backed wrapper for Julich-Brain / Brodmann-style cytoarchitectonic labels (get_julich_brain_atlas()), which now downloads the Nilearn/NITRCJuelich.tgzarchive into a local FSL-style cache whenFSLDIRis unset.plot_brain(overlay = <NeuroVol>)now propagates missing data through the volume-to-surface projection: vertices that fall outside the input volume’s coverage (or whose neighbourhood contains no finite source voxel) are emitted asNArather than0. Faces with no finite vertices are dropped from the polygon set, so uncovered cortex renders as transparent background instead of an opaque dark-palette wash. Faces with partial coverage continue to render using the average of their finite vertices. The internalvol_to_surf()fillargument changed from0toNA_real_.plot_brain(overlay = <NeuroVol>)now repairs legacySurfaceGeometryobjects on the fly. The bundleddata(fsaverage)artefact and the@geometryslots inside packaged surface atlases were serialized beforeneurosurf::SurfaceGeometrygained thelabelandsurf_to_worldslots; accessing those slots on a legacy object errored out and causedvol_to_surf()to silently return all-NA overlays..resolve_overlay_surface_pair()now rebuilds any geometry that failsvalidObject()via the current constructor before passing it tovol_to_surf().Added a canonical
new_atlas()/new_surfatlas()constructor that assembles every loader’s return value (Schaefer, Glasser, ASEG, Olsen MTL / hippocampus, TemplateFlow subcortical). The constructor validates required fields with a typedneuroatlas_error_invalid_atlascondition, normalises RGB colour maps to a data frame, buildsroi_metadatauniformly, and attachesatlas_ref/ provenance in one place — removing ~100 lines of per-loader boilerplate.Added a lightweight atlas registry (
register_atlas()) exposed via two new public helpers:list_atlases()enumerates the built-in atlases, andget_atlas(name, ...)dispatches to the registered loader by id or alias (e.g.get_atlas("schaefer2018", parcels="100", networks="7")).Added centralised download helpers (
.neuroatlas_download(),.neuroatlas_try_download()) used by the Schaefer and Glasser loaders. Failures now raise classedneuroatlas_error_downloadconditions with the upstream URL instead of returning a silentNULL; Git LFS pointer stubs are detected and reported explicitly.Atlas loaders now emit
cli::cli_abort()/cli::cli_warn()with structured classes (neuroatlas_error_*,neuroatlas_warn_*) in place of barestop()/warning(), so callers can catch loader errors by class.Added atlas provenance descriptors via new
atlas_refinfrastructure:new_atlas_ref(),atlas_ref(),atlas_family(),atlas_space(),atlas_coord_space(), andvalidate_atlas_ref().Atlas constructors now attach structured provenance/space metadata and compatibility aliases (
space,template_space,coord_space,confidence) for Schaefer, Glasser, ASEG, Olsen MTL/hippocampus, and TemplateFlow subcortical atlases.get_glasser_atlas()now accepts asourceargument and defaults tosource = "mni2009c"with fallback to legacyxcpenginewhen unavailable. Fallback paths are tagged withconfidence = "uncertain".Added
test-atlas-ref.Rcoverage for atlas reference metadata and basic cross-representation label concordance checks.Added space-level transform planning utilities backed by
inst/extdata/transform_registry.csv:space_transform_manifest(),atlas_transform_plan(), and scope-awareatlas_transform_manifest().atlas_alignment()now consults the space transform registry for same-representation cross-template routes (e.g., NLin6Asym to 2009cAsym) and reports route-specific status/confidence.Fixed white gaps (“shards”) in
plot_brain()surface rendering caused by inconsistent triangle winding in some meshes.Added
silhouette*andnetwork_border*options toplot_brain()for improved boundary styling (silhouette outline and between-network borders).Improved
plot_brain()aesthetics with smoother boundary rendering (border_geom = "path") and an optional normal-based shading overlay (shading*,fill_alpha).
neuroatlas 0.1.0
- Initial CRAN submission
- Added support for multiple neuroimaging atlases:
- Schaefer cortical parcellations (100-1000 parcels, 7/17 networks)
- Glasser multi-modal parcellation (360 regions)
- FreeSurfer ASEG subcortical segmentation
- Olsen medial temporal lobe atlas
- Integrated TemplateFlow support for standardized templates
- Added visualization support via ggseg and echarts4r
- Implemented atlas operations: ROI extraction, data reduction, resampling
- Added comprehensive vignettes and documentation