.TH MHISTOGRAM 1 "Dec 2016" "Montage 5" "Montage" .SH NAME mHistogram \- None .SH SYNOPSIS mHistogram [\-d] \-file \fIin.fits minrange maxrange [logpower/gaussian/gaussian-log/asinh [asinh-beta]]\fP \-out \fIout.hist\fP .SH DESCRIPTION The mViewer application makes PNG/JPEG files using FITS images as input. Part of that processing involves analyzing the FITS files and creating a histogram that is used to inform the transformation from pixel values to display colors/intensities. This processing is done inside mViewer itself. However, there are situations where it helps to have the histogram earlier. For instance, you may have several images to process into PNGs and wish to use the same histogram-based stretch for each one. Or you may want to generate a set of pixel values that give the visual impression of a color bar (see mPad). Sometimes, you may just want the histogram itself for display or analysis purposes. The mHistogram module contains the same histogram code as mViewer but writes the results out to an ASCII file which can then be read in by mHistogram, mPad or user programs. .SH OPTIONS .TP \-d Turn on debugging. .TP \-file \fIin.fits minrange maxrange [logpower/gaussian/gaussian-log/asinh [asinh-beta]]\fP The FITS image file; stretch range; and (optionally) stretch mode. See the mViewer documentation for more details. .TP \-out \fIout.hist\fP Output histogram (ASCII) file. .SH RESULT If successful, the result is an ASCII file containing the histogram data, color table lookup mapping, and some other information. .SH MESSAGES .TP ERROR Too few arguments following \-file flag .TP ERROR Image file \fIbadfile\fP invalid FITS .TP ERROR Can't find HDU \fIbadHDU\fP .TP ERROR Too few arguments following \-out flag .TP ERROR No input FITS file name given .TP ERROR No output histogram file name given .TP ERROR Cannot open output histogram file. .TP ERROR Grayscale/pseudocolor mode but no gray image given .TP ERROR \fIFITS library error\fP .TP ERROR leading numeric term in '\fIstring\fP' cannot be converted to a finite floating point number .TP ERROR not a valid \fIdatatype\fP .TP ERROR negative percentile .TP ERROR percentile \fIcontext\fP larger than 100 .TP ERROR extra numeric term in \fIcontext\fP '\fIstring\fP' cannot be converted to a finite floating point number .TP ERROR \fIcontext\fP '\fIstring\fP' contains trailing junk .SH EXAMPLES .TP mHistogram \-file SDSS_r.fits \-2s max gaussian-log \-out SDSS_r.hist [struct stat="OK"] .SH BUGS The drizzle algorithm has been implemented but has not been tested in this release. .PP If a header template contains carriage returns (i.e., created/modified on a Windows machine), the cfitsio library will be unable to read it properly, resulting in the error: [struct stat="ERROR", status=207, msg="illegal character in keyword"] .PP It is best for the background correction algorithms if the area described in the header template completely encloses all of the input images in their entirety. If parts of input images are "chopped off" by the header template, the background correction will be affected. We recommend you use an expanded header for the reprojection and background modeling steps, returning to the originally desired header size for the final coaddition. The default background matching assumes that there are no non-linear background variations in the individual images (and therefore in the overlap differences). If there is any uncertainty in this regard, it is safer to turn on the "level only" background matching (the "\-l" flag in mBgModel. .SH COPYRIGHT 2001-2015 California Institute of Technology, Pasadena, California .PP If your research uses Montage, please include the following acknowledgement: "This research made use of Montage. It is funded by the National Science Foundation under Grant Number ACI-1440620, and was previously funded by the National Aeronautics and Space Administration's Earth Science Technology Office, Computation Technologies Project, under Cooperative Agreement Number NCC5-626 between NASA and the California Institute of Technology." .PP The Montage distribution includes an adaptation of the MOPEX algorithm developed at the Spitzer Science Center.