Skip to contents

Exports a QSM in the QSM Blender Addons format

Usage

export_blender(cylinder, filename)

Arguments

cylinder

QSM cylinder data frame

filename

File name and path for exporting. The .txt extension is automatically added if not present.

Value

A .txt file

Examples


file <- system.file("extdata/QSM.mat", package = "rTwig")
qsm <- run_rtwig(file, twig_radius = 4.23, metrics = FALSE, smooth = TRUE)
#> Importing TreeQSM
#> Updating Cylinder Ordering
#> Calculating Total Children
#> Building Cylinder Network
#> Caching Network
#> Verifying Topology
#> Calculating Growth Length
#> Calculating Reverse Branch Order
#> Calculating Branch Segments
#> Calculating Alternate Branch Numbers
#> Calculating Path Metrics
#> Smoothing QSM
#> Generating Paths
#> Filtering Paths
#> Modeling Paths
#> Updating Radii

filename <- tempfile(pattern = "qsm_blender")
export_blender(qsm, filename)