Save transform as .mat


Could some please help me to save a LinearTransform as .mat file using commandline pls.

I have checked script repository , and tried chat GPT ,
Could find anything.

I generate 50-100 linear transforms (after model registration) with displacement data, that needs saving as .mat files , so I am hoping to do it CLI and loop


I would recommend to save as .txt file. It is human-readable and easy to read and write in both Slicer and Matlab.

Matlab reader and writer are available here: