edu.jhu.pha.sdss.fits
Class Histogram
java.lang.Object
edu.jhu.pha.sdss.fits.Histogram
- public class Histogram
- extends java.lang.Object
Current Version
===============
ID: $Id: Histogram.html,v 1.1 2004/07/23 22:04:49 carliles Exp $
Revision: $Revision: 1.1 $
Date/time: $Date: 2004/07/23 22:04:49 $
|
Nested Class Summary |
static class |
Histogram.Bounds
A container class used by the calculateBounds method. |
|
Constructor Summary |
Histogram(double min,
double max,
int totalCount,
int[] counts)
|
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Histogram
public Histogram(double min,
double max,
int totalCount,
int[] counts)
getMin
public double getMin()
getMax
public double getMax()
getRange
public double getRange()
getTotalCount
public int getTotalCount()
getCounts
public int[] getCounts()
getEqualizedValue
public int getEqualizedValue(int val)
- Returns:
- A histogram equalized value for
val. val
must be in the range [0, 65535], and is interpreted to be a linear scaling
of an original data value.
estimateSigma
public double estimateSigma()
- Returns:
- A reasonable guess at a good sigma value for the inverse hyperbolic
sine scaling. The estimate is made by finding the mode value of the
histogram, then moving to the next bin and returning the value (in the
original data range with bZero and bScale applied) at the "bottom" of that
bin. The current implementation is actually a mangled implementation which
happens to produce better sigmas than the correct implementation. An
explanation for this behavior is currently being investigated.
calculateBounds
public Histogram.Bounds calculateBounds(double percentKept)
throws java.lang.IllegalArgumentException
- Returns:
- An instance of
Bounds containing the min and max
values that will result in keeping percentKept percent of the
values in the image. percentKept is a slightly deceptive
name, as it must be in the range [0, 1].
- Throws:
java.lang.IllegalArgumentException
revision
public static java.lang.String revision()
- Returns:
- CVS Revision number.