Package adams.data.filter
Class AbstractDerivative<T extends DataContainer>
- java.lang.Object
-
- adams.core.logging.LoggingObject
-
- adams.core.logging.CustomLoggingLevelObject
-
- adams.core.option.AbstractOptionHandler
-
- adams.data.filter.AbstractFilter<T>
-
- adams.data.filter.AbstractDerivative<T>
-
- Type Parameters:
T- the type of data to filter
- All Implemented Interfaces:
CleanUpHandler,Destroyable,GlobalInfoSupporter,LoggingLevelHandler,LoggingSupporter,OptionHandler,ShallowCopySupporter<Filter>,SizeOfHandler,Filter<T>,Serializable,Comparable
- Direct Known Subclasses:
TimeseriesDerivative
public abstract class AbstractDerivative<T extends DataContainer> extends AbstractFilter<T>
Abstract ancestor for Derivative filters.- Version:
- $Revision$
- Author:
- fracpete (fracpete at waikato dot ac dot nz)
- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classAbstractDerivative.PointContainer class for abundance and timestamp in double format.-
Nested classes/interfaces inherited from class adams.data.filter.AbstractFilter
AbstractFilter.FilterJob<T extends DataContainer>
-
-
Field Summary
Fields Modifier and Type Field Description protected intm_Orderthe order of the derivative.protected doublem_ScalingRangethe range to scale the abundances to after each derivation step.-
Fields inherited from class adams.data.filter.AbstractFilter
m_DontUpdateID
-
Fields inherited from class adams.core.option.AbstractOptionHandler
m_OptionManager
-
Fields inherited from class adams.core.logging.LoggingObject
m_Logger, m_LoggingIsEnabled, m_LoggingLevel
-
-
Constructor Summary
Constructors Constructor Description AbstractDerivative()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description voiddefineOptions()Adds options to the internal list of options.protected List<AbstractDerivative.Point>derive(List<AbstractDerivative.Point> data)Generates the next derivative from the GC data.intgetOrder()Returns the order of the derivative to calculate.doublegetScalingRange()Returns the scaling range the abundances are scaled to after each derivation step (= 0 means no scaling; -1 sets scaling to input range).StringorderTipText()Returns the tip text for this property.protected TprocessData(T data)Performs the actual filtering.StringscalingRangeTipText()Returns the tip text for this property.voidsetOrder(int value)Sets the order of the derivative to calculate.voidsetScalingRange(double value)Sets the range to scale the abundances to after each derivation step (= 0 turns scaling off; -1 sets scaling to input range).protected abstract DataPointtoDataPoint(AbstractDerivative.Point point)Turns the intermediate format point back into a DataPoint.protected abstract AbstractDerivative.PointtoPoint(DataPoint point)Turns the DataPoint into the intermediate format.-
Methods inherited from class adams.data.filter.AbstractFilter
checkData, cleanUp, compareTo, destroy, dontUpdateIDTipText, equals, filter, forCommandLine, getDontUpdateID, reset, setDontUpdateID, shallowCopy, shallowCopy
-
Methods inherited from class adams.core.option.AbstractOptionHandler
cleanUpOptions, finishInit, getDefaultLoggingLevel, getOptionManager, globalInfo, initialize, loggingLevelTipText, newOptionManager, setLoggingLevel, toCommandLine, toString
-
Methods inherited from class adams.core.logging.LoggingObject
configureLogger, getLogger, getLoggingLevel, initializeLogging, isLoggingEnabled, sizeOf
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface adams.core.logging.LoggingLevelHandler
getLoggingLevel, setLoggingLevel
-
Methods inherited from interface adams.core.logging.LoggingSupporter
getLogger, isLoggingEnabled
-
Methods inherited from interface adams.core.option.OptionHandler
cleanUpOptions, getOptionManager, toCommandLine
-
-
-
-
Method Detail
-
defineOptions
public void defineOptions()
Adds options to the internal list of options.- Specified by:
defineOptionsin interfaceOptionHandler- Overrides:
defineOptionsin classAbstractFilter<T extends DataContainer>
-
setOrder
public void setOrder(int value)
Sets the order of the derivative to calculate.- Parameters:
value- the order
-
getOrder
public int getOrder()
Returns the order of the derivative to calculate.- Returns:
- the order
-
orderTipText
public String orderTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the gui
-
setScalingRange
public void setScalingRange(double value)
Sets the range to scale the abundances to after each derivation step (= 0 turns scaling off; -1 sets scaling to input range).- Parameters:
value- the range
-
getScalingRange
public double getScalingRange()
Returns the scaling range the abundances are scaled to after each derivation step (= 0 means no scaling; -1 sets scaling to input range).- Returns:
- the range
-
scalingRangeTipText
public String scalingRangeTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the gui
-
derive
protected List<AbstractDerivative.Point> derive(List<AbstractDerivative.Point> data)
Generates the next derivative from the GC data.- Parameters:
data- the data to derive- Returns:
- the derived data
-
toPoint
protected abstract AbstractDerivative.Point toPoint(DataPoint point)
Turns the DataPoint into the intermediate format.- Parameters:
point- the DataPoint to convert- Returns:
- the generated intermediate format point
-
toDataPoint
protected abstract DataPoint toDataPoint(AbstractDerivative.Point point)
Turns the intermediate format point back into a DataPoint.- Parameters:
point- the intermediate format point to convert- Returns:
- the generated DataPoint
-
processData
protected T processData(T data)
Performs the actual filtering.- Specified by:
processDatain classAbstractFilter<T extends DataContainer>- Parameters:
data- the data to filter- Returns:
- the filtered data
-
-