Take the 2-minute tour ×
Mathematica Stack Exchange is a question and answer site for users of Mathematica. It's 100% free, no registration required.

I am using GATE/Geant4 for simulating photon beams interacting with matter. For 3D dose distributions, GATE outputs the data into an Analyze 7.5 format [1]. I was wondering whether there exists a function in Mathematica that could read files in this format and display the data. For what is worth, Matlab has analyze75read [2] for this purpose.

[1] http://eeg.sourceforge.net/ANALYZE75.pdf

[2] http://www.mathworks.com/help/images/ref/analyze75read.html

( This comment will soon be deleted: I don't have access at the moment to my Mathematica installation, but here is a file in case anyone would like to play with it: http://leaf.dragonflybsd.org/~beket/geant4/Config-gamma-Dose.hdr and http://leaf.dragonflybsd.org/~beket/geant4/Config-gamma-Dose.img ).

share|improve this question
    
Just found a viewer that is able to read/display .hdr/.img files: creatis.insa-lyon.fr/rio/vv –  Zet Oct 6 '13 at 12:49
add comment

1 Answer

If you have both Mathematica and MATLAB (with the Image Processing Toolbox, of course) installed on the same computer, an easy way would be to use MATLAB to read the file, and then pass the data to Mathematica using MATLink. This would avoid the need for you (or someone else) to write C code as a LibraryLink program, which (judging from the description of the file format) would be the only other reasonably straightforward and/or performant approach.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.