public class MatrixSeries extends Series implements java.io.Serializable
Modifier and Type | Field and Description |
---|---|
protected double[][] |
data
Series matrix values
|
Constructor and Description |
---|
MatrixSeries(java.lang.String name,
int rows,
int columns)
Constructs a new matrix series.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object obj)
Tests this object instance for equality with an arbitrary object.
|
double |
get(int i,
int j)
Returns the value of the specified item in this matrix series.
|
int |
getColumnsCount()
Returns the number of columns in this matrix series.
|
java.lang.Number |
getItem(int itemIndex)
Return the matrix item at the specified index.
|
int |
getItemColumn(int itemIndex)
Returns the column of the specified item.
|
int |
getItemCount()
Returns the number of items in the series.
|
int |
getItemRow(int itemIndex)
Returns the row of the specified item.
|
int |
getRowCount()
Returns the number of rows in this matrix series.
|
void |
update(int i,
int j,
double mij)
Updates the value of the specified item in this matrix series.
|
void |
zeroAll()
Sets all matrix values to zero and sends a
SeriesChangeEvent to all registered
listeners. |
addChangeListener, addPropertyChangeListener, addVetoableChangeListener, clone, firePropertyChange, fireSeriesChanged, fireVetoableChange, getDescription, getKey, getNotify, hashCode, isEmpty, notifyListeners, removeChangeListener, removePropertyChangeListener, removeVetoableChangeListener, setDescription, setKey, setNotify
protected double[][] data
public MatrixSeries(java.lang.String name, int rows, int columns)
By default, all matrix items are initialzed to 0.
name
- series name (null
not permitted).rows
- the number of rows.columns
- the number of columns.public int getColumnsCount()
public java.lang.Number getItem(int itemIndex)
Double
instance every time it is called.itemIndex
- item index.get(int, int)
public int getItemColumn(int itemIndex)
itemIndex
- the index of the item.public int getItemCount()
getItemCount
in class Series
public int getItemRow(int itemIndex)
itemIndex
- the index of the item.public int getRowCount()
public double get(int i, int j)
i
- the row of the item.j
- the column of the item.getItem(int)
,
update(int, int, double)
public void update(int i, int j, double mij)
i
- the row of the item.j
- the column of the item.mij
- the new value for the item.get(int, int)
public void zeroAll()
SeriesChangeEvent
to all registered
listeners.