[Insight-users] How can I write a Histogram to file?

Luis Ibanez luis . ibanez at kitware . com
Tue, 09 Dec 2003 13:49:26 -0500


Hi Estanislao,

There isn't a standard filter for writing Histograms to file.
You may have to design your own file format for this type of data.

Note that in addition to the frequencies you may want to save
the minimum and maximum values defining the bins, the number
of bins along each dimension and a description of the data type
used for the domain.

If you are using a Histogram with uniform bin size, you could
probably write an adaptor for presenting the histogram as an
ITK image, and then use the standard image file writers.

An XML based style for writing the histogram is also a nice
option to consider...

Please let us know if you find any difficulty in this process.


Thanks


   Luis


----------------------------
Estanislao Oubel wrote:

> Hi all,
>  
> I'd like to know if it's possible to write a 
> /itk::Statistics::Histogram/ object to file. I've read the ITK 
> Software Guide and I know how to use /itk::ImageFileWriter/ with 
> /itk::Image/. Is there any similar function to save histograms?
>  
> Thanks in advance,
>  
> Estanislao. 
>
>