as.list.fs.tracts: Convert an fs.tracts instance to a plain list of tracts.

View source: R/fs_tracts.R

as.list.fs.tractsR Documentation

Convert an fs.tracts instance to a plain list of tracts.

Description

Converts to the classic representation as a list with one entry per tract. This is convenient for interacting with code that expects a plain list, but note that it materializes one R object per tract and is therefore much more expensive in both memory and time. Prefer [[ for accessing individual tracts.

Usage

## S3 method for class 'fs.tracts'
as.list(x, ...)

Arguments

x

an fs.tracts instance.

...

ignored.

Value

list with one entry per tract.

Examples

## Not run: 
tck <- read.dti.tck("brain.tck");
tracts_list <- as.list(tck$tracks);

## End(Not run)


freesurferformats documentation built on Sept. 25, 2026, 1:07 a.m.