Dear Geon-Hu,
beacuse most of the tags are missing from the analyze header, the best way
is:
(to create a dicom mosaic from analyze)
1. to find a dicom mosaic file (Template.dcm) containing tag information
same as needed.
2. read your analyze file from slice to slice and put these sclices into a
2D matrix with quadratic size (Data):
e.g: if your matrix size: 128x128 (one plane) and your volume contains 24
slices, your 2D matrix must be:
(ceil(sqrt(24))x128) x (ceil(sqrt(24))x128). Of course it must fit with with
the matrix of Template.dcm.
3. then you can use this matlab command to create a dicom mosaic file with
the header of Template.dcm and data of Data:
dicomwrite(Data, gray, "filename for your new dicom file",
dicominfo("template.dcm"), 'CreateMode', 'copy');
I hope, it helps.
If you want to create separate dicom files slice by slice, you can use
separate Template.dcm-s.
Regards,
Auer, Tibor MD.
PhD-student
PU-MF, Neurosurgery Clinic
2. Rét str. Pécs, HU-7623
+36-20-986-9341
[log in to unmask]
|