|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object
|
+--java.util.Observable
|
+--hep.analysis.Partition
|
+--hep.analysis.partition.Abstract1DPartition
The base class for all one-dimensional partitions.
All fill methods
will throw a PartitionFillException if not overridden. Therefore,
subclasses should override the methods corresponding to the data
types the subclass supports and leave the remaining ones to throw
exceptions. Similarly, all getBinAt methods throw a
NoSuchBinException unless overridden so subclasses should override the
methods corresponding to the types that the subclass supports.
PartitionFillException,
NoSuchBinException, Serialized Form| Fields inherited from class hep.analysis.Partition |
DATE, DELTATIME, DOUBLE, HORIZONTAL_AXIS, INTEGER, m_owner, STRING, VERTICAL_AXIS |
| Constructor Summary | |
Abstract1DPartition()
|
|
| Method Summary | |
void |
clear()
Resets the partition to default settings. |
protected void |
clearDataChanged()
Indicate that all data changes have been acknowledged by the observer and that the partition should resume sending new updates. |
protected void |
clearRangeChanged()
Indicate that all range changes have been acknowledged by the observer and that the partition should resume sending new updates. |
void |
done()
Called when event loop is finished; sends a final update of any range and/or data change. |
void |
fill(java.util.Date x)
Invokes the fill(Date, double) method with
a weighting value of 1. |
void |
fill(java.util.Date x,
double y)
|
void |
fill(double x)
Invokes the fill(double, double) method with
a weighting value of 1. |
void |
fill(double x,
double y)
|
void |
fill(int x)
Invokes the fill(int, double) method with
a weighting value of 1. |
void |
fill(java.lang.String x)
Invokes the fill(String, double) method with
a weighting value of 1. |
void |
fillW(java.util.Date x,
double v)
Fills the associated histogram with a date value. |
void |
fillW(java.util.Date x,
double y,
double weight)
|
void |
fillW(double x,
double v)
Fills the associated histogram with a numerical value. |
void |
fillW(double x,
double y,
double weight)
|
void |
fillW(int x,
double v)
Converts the given int parameter to type
double and calls fill(double, double). |
void |
fillW(java.lang.String x,
double v)
Fills the associated histogram with a string value. |
java.lang.String[] |
getAxisLabels()
Override to allow axis labels to be accessed. |
int |
getAxisType()
Return the Axis type |
double |
getBin(int bin)
Returns the contents of the given bin. |
int |
getBinAt(java.util.Date x)
Returns the bin index corresponding to the given date value. |
int |
getBinAt(double x)
Returns the bin index corresponding to the given numerical value. |
int |
getBinAt(int x)
Converts the given int parameter to type
double and invokes the method
getBinAt(double). |
int |
getBinAt(java.lang.String x)
Returns the bin index corresponding to the given string value. |
abstract double[] |
getBins()
Return an array containing the sizes of all the bins. |
double |
getError(int bin)
Returns the error for the given bin. |
abstract double |
getMax()
Return the maximum in the distribution. |
abstract double |
getMin()
Return the minimum in the distribution. |
double |
getMinusError(int bin)
Returns the minus error for the given bin. |
abstract double[] |
getMinusErrors()
|
abstract int |
getNumberOfBins()
Return the number of bins. |
double |
getPlusError(int bin)
Returns the plus error for the given bin. |
abstract double[] |
getPlusErrors()
Return an array containing the errors for all the bins. |
boolean |
hasAsymmetricErrorBars()
Returns false by default. |
boolean |
hasSimpleQuadraticErrorBars()
Returns false by default. |
boolean |
isRebinnable()
Returns false by default. |
void |
notifyObservers(java.lang.Object arg)
|
void |
rangeChanged(double min,
double max)
Implementation of RangeChangeListener |
void |
setBinning(int bins,
double min,
double max)
Override to allow binning to be set. |
protected void |
setDataAndRangeChanged()
Indicate that the data and range have changed and notify observers of the change. |
protected void |
setDataAndRangeChangedNow()
Indicate that the data and range have changed and notify observers of the change with a final update. |
protected void |
setDataChanged()
Indicate that the data have changed and notify observers of the change. |
protected void |
setRangeChanged()
Indicate that the range has changed and notify observers of the change. |
| Methods inherited from class hep.analysis.Partition |
destroy, getStyle, makeCopy, setStyle |
| Methods inherited from class java.util.Observable |
addObserver, clearChanged, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, setChanged |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface hep.analysis.partition.StatisticsProvider |
getStatistics |
| Constructor Detail |
public Abstract1DPartition()
| Method Detail |
public void fillW(double x,
double v)
x - the value to fillv - a partition-specific value (normally some weighting value)PartitionFillException - if this method is not overriddenPartitionFillException
public void fillW(int x,
double v)
int parameter to type
double and calls fill(double, double).x - the value to fillv - a partition-specific value (normally some weighting value)PartitionFillException - if thrown from fill(double, double)fill(double, double),
PartitionFillException
public void fillW(java.lang.String x,
double v)
x - the value to fillv - a partition-specific value (normally some weighting value)PartitionFillException - if not overriddenPartitionFillException
public void fillW(java.util.Date x,
double v)
x - the value to fillv - a partition-specific value (normally some weighting value)PartitionFillException - if not overriddenPartitionFillExceptionpublic void fill(double x)
fill(double, double) method with
a weighting value of 1.x - the value to fillfillW(double, double)public void fill(int x)
fill(int, double) method with
a weighting value of 1.x - the value to fillfillW(int, double)public void fill(java.lang.String x)
fill(String, double) method with
a weighting value of 1.x - the value to fillfillW(String, double)public void fill(java.util.Date x)
fill(Date, double) method with
a weighting value of 1.x - the value to fillfillW(Date, double)
public void fill(double x,
double y)
public void fillW(double x,
double y,
double weight)
public void fill(java.util.Date x,
double y)
public void fillW(java.util.Date x,
double y,
double weight)
public int getBinAt(double x)
throws NoSuchBinException
x - the value to map to a binxNoSuchBinException - if not overridden
public int getBinAt(int x)
throws NoSuchBinException
int parameter to type
double and invokes the method
getBinAt(double).NoSuchBinException - if thrown from getBinAt(double)getBinAt(double)
public int getBinAt(java.lang.String x)
throws NoSuchBinException
x - the value to map to a binxNoSuchBinException - if not overridden
public int getBinAt(java.util.Date x)
throws NoSuchBinException
x - the value to map to a binxNoSuchBinException - if not overridden
public double getBin(int bin)
throws NoSuchBinException
bin - the bin to return the content ofNoSuchBinException - if the parameter bin is invalidpublic boolean hasAsymmetricErrorBars()
hasAsymmetricErrorBars in interface OneDDataSourcepublic boolean hasSimpleQuadraticErrorBars()
hasSimpleQuadraticErrorBars in interface OneDDataSourcepublic double getPlusError(int bin)
getPlusErrors()[bin].bin - the bin to return the plus error onNoSuchBinException - if the parameter bin is invalidgetPlusErrors()public double getMinusError(int bin)
getMinusErrors()[bin].bin - the bin to return the minus error onNoSuchBinException - if the parameter bin is invalidgetMinusErrors()public double getError(int bin)
public boolean isRebinnable()
isRebinnable in interface OneDDataSource
public void setBinning(int bins,
double min,
double max)
setBinning in interface OneDDataSourcebins - the number of bins to havemin - the minimum of the partition rangemax - the maximum of the partition rangeUnsupportedPartitionMethodException - if not overridden.public java.lang.String[] getAxisLabels()
getAxisLabels in interface OneDDataSourcepublic int getAxisType()
getAxisType in interface OneDDataSourcepublic abstract double[] getBins()
getBins in interface OneDDataSourcepublic abstract double[] getPlusErrors()
getPlusErrors in interface OneDDataSourcepublic abstract double[] getMinusErrors()
getMinusErrors in interface OneDDataSourcepublic abstract int getNumberOfBins()
public abstract double getMin()
getMin in interface OneDDataSourcepublic abstract double getMax()
getMax in interface OneDDataSourceprotected final void setDataChanged()
public void rangeChanged(double min,
double max)
rangeChanged in interface RangeChangeListenerprotected final void setDataAndRangeChanged()
protected final void setDataAndRangeChangedNow()
protected final void clearDataChanged()
protected final void setRangeChanged()
protected final void clearRangeChanged()
public void clear()
clear in class Partitionpublic void done()
done in class Partitionpublic final void notifyObservers(java.lang.Object arg)
notifyObservers in class java.util.Observable
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||