Package hec.gfx2d
Class ComplexSeasonalData
java.lang.Object
java.util.Observable
hec.gfx2d.G2dData
hec.gfx2d.ComplexSeasonalData
- All Implemented Interfaces:
G2dObject
,Serializable
This plot object calculates a single plot line for mulitple SimpleSeasonalData. It collects
all of the unique date values from each SimpleSeasonalData and interpolates values for each
date from all records and sums them together. This acts similar to the SimpleSeasonalData object
which plots a single SeasonalRecord.
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected String
protected int
protected Vector
int[]
int[]
double[]
double[]
Fields inherited from interface hec.gfx2d.G2dObject
RESET_DATA, UPDATE_DATA
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
Adds a new seasonal record to the list.boolean
Returns the extents of the object in world coordinatesReturns the point in local coordinates of the closest data point to the given ptReturns the name of the x axisint
Returns the name of the x axisReturns the name of the y axisint
Returns the name of the y axisvoid
load()
Causes the object to load its data into memoryvoid
sets the vector of seasonal recordsvoid
setInterpolationType
(String interpType) set interpolation typevoid
setYAxisName
(String name) Set the name of the y-axisvoid
unload()
Causes the object to unload its data from memoryMethods inherited from class hec.gfx2d.G2dData
addObserver, canSwapXYValues, getCurveCount, getDefaultMaxYValue, getDefaultMinYValue, getGmtOffset, getLineStyleName, getLookup, getName, getUnitSystem, getXParameterId, getXValues, getYParameterId, getYValues, hasDefaultMaxYValue, hasDefaultMinYValue, setDefaultMaxYValue, setDefaultMinYValue, setGmtOffset, setName, setSwapXYValues, setUnitSystem, setUseDisplayUnits, setXParameterId, setYParameterId, swapXYValues, toString, useDisplayUnits
Methods inherited from class java.util.Observable
clearChanged, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, notifyObservers, setChanged
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface hec.gfx2d.G2dObject
canSwapXYValues, getCurveCount, getDataZoneId, getDefaultMaxYValue, getDefaultMinYValue, getGmtOffset, getLineStyleName, getLookup, getName, getUnitSystem, getXParameterId, getXValues, getYParameterId, getYValues, hasDefaultMaxYValue, hasDefaultMinYValue, setDefaultMaxYValue, setDefaultMinYValue, setSwapXYValues, swapXYValues
-
Field Details
-
_tdata
public int[] _tdata -
_ydata
public double[] _ydata -
_tdataOrg
public int[] _tdataOrg -
_ydataOrg
public double[] _ydataOrg -
_xtype
-
_ytype
-
_srVector
-
_interpolationType
-
_nyears
protected int _nyears
-
-
Constructor Details
-
ComplexSeasonalData
public ComplexSeasonalData()
-
-
Method Details
-
setData
sets the vector of seasonal records -
addData
Adds a new seasonal record to the list. The user should call calcPlotArrays to redo the calculation -
calcPlotArrays
public boolean calcPlotArrays() -
setInterpolationType
set interpolation type -
getBounds
Returns the extents of the object in world coordinates -
getXAxisName
Returns the name of the x axis- Specified by:
getXAxisName
in interfaceG2dObject
-
getYAxisName
Returns the name of the y axis- Specified by:
getYAxisName
in interfaceG2dObject
-
setYAxisName
Set the name of the y-axis -
getXAxisType
public int getXAxisType()Returns the name of the x axis- Specified by:
getXAxisType
in interfaceG2dObject
-
getYAxisType
public int getYAxisType()Returns the name of the y axis- Specified by:
getYAxisType
in interfaceG2dObject
-
load
public void load()Description copied from interface:G2dObject
Causes the object to load its data into memory -
unload
public void unload()Description copied from interface:G2dObject
Causes the object to unload its data from memory -
getNearestDataPt
Returns the point in local coordinates of the closest data point to the given pt
-