Class for parsing a file which holds initial estimates for 2-D components. Used by imfit.
More...
Class for parsing a file which holds initial estimates for 2-D components. Used by imfit.
Intended use:
Public interface
Review Status
- Test programs:
- tFitterEstimatesFileParser
Prerequisite
Synopsis
Used for reading files containing initial estimates of models for 2-D fitting. The expected format is:
-
Lines with a "#" in column 1 are treated as comments and ignored.
-
Each non-comment line is treated as a complete set of six comma-delimited parameters for specifying an estimate for a component. The values are Flux (quantity), x pixel position of peak (double), y pixel position of peak (double), FWHM major axis (quantity), FWHM minor axis (quantity), position angle (measured from north to east (quantity).
-
Optionally, a component estimate line can have a seventh parameter which is a string specifying which of the parameters for that component should be held fixed during the fit. This string can include any combination of the following identifiers: "f" flux, "x" x position, "y" y position, "a" major axis, "b" minor axis, "p" position angle. So, eg, "apx" means hold the major axis, position angle, and x position constant during the fit.
If the specified file passed to the constructor does not exist, an exception is thrown. Parsing is done during object construction and an exception is thrown if the file does not have the expected format.
Example
FitterEstimatesFilebFileReader reader("myEstimates.txt", myImage);
ComponentList cl = reader.getEstimates();
Definition at line 81 of file FitterEstimatesFileParser.h.