Create 4D file ( x,y,z,t) from individual volumes

Hello everyone,
I have a series of consecutive volumes (3D ultrasound images) as .mat files (which I then save as .tif to load them in ImageJ) and I want to construct a 4D Analyze file. I thought that this could be done as a hyperstack, but I haven’t figured out how exactly to do it (I was trying with the “New Hyperstack” and “Stack to Hyperstack”)
I would appreciate any kind of help.
Best regards,

Hi @thanoskt,
Welcome to the forum.

I think
Image > Stacks > Tools > Concatenate...
(with “Open as 4D image” checked), is what you’re looking for.

Post back if it doesn’t do what you expect (and also if it does).



Hey @bogovicj,

Thank you very much for your reply. Concatenate seems to do exactly what I was looking for!

My problem now is that I save my volumes as “Analyze” and when I load them to the software that I am working on, I get consecutive slices on the z axis (e.g. 1000) instead of separate volumes (e.g. 10 volumes of 100 z slices each). But I guess there is no option to edit the header of my file (e.g. the number of volumes in each direction) in ImageJ , right?
Thank you!


Actually I tried to save it as Analyze (NIfTI-1) as well, instead of just Analyze, and it worked fine! So you can ignore my last question.

1 Like

Out of curiosity, and so it might help others in the future as well, what was the other piece of software you’re working with, that readthe Nifti correctly, but not the Analyze?

I am trying a software that was developed in the Yale university, called BioImage Suite. It is used (among others) for cardiac image analysis.