Class IntegerMatrix<R,C>
- java.lang.Object
-
- ubic.basecode.dataStructure.matrix.AbstractMatrix<R,C,Integer>
-
- ubic.basecode.dataStructure.matrix.IntegerMatrix<R,C>
-
- All Implemented Interfaces:
Serializable
,Matrix2D<R,C,Integer>
,PrimitiveMatrix<R,C,Integer>
public class IntegerMatrix<R,C> extends AbstractMatrix<R,C,Integer> implements PrimitiveMatrix<R,C,Integer>
- Author:
- pavlidis
- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class ubic.basecode.dataStructure.matrix.AbstractMatrix
MAX_ROWS_TO_PRINT
-
-
Constructor Summary
Constructors Constructor Description IntegerMatrix(int x, int y)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
columns()
Get the number of columns the matrix has.Integer
get(int row, int column)
Integer
getByKeys(R r, C c)
Integer[]
getColObj(int col)
Integer[]
getColumn(int col)
Integer
getEntry(int row, int column)
Integer
getObject(int row, int col)
Integer[]
getRow(int row)
Integer[]
getRowObj(int row)
boolean
isMissing(int i, int j)
Check if the value at a given index is missing.int
rows()
Get the number of rows the matrix hasvoid
set(int row, int column, Integer value)
void
setByKeys(R r, C c, Integer v)
void
setObj(int row, int column, Integer value)
int
size()
String
toString()
-
Methods inherited from class ubic.basecode.dataStructure.matrix.AbstractMatrix
addColumnName, addRowName, asDoubles, assign, checkColRange, checkRowRange, containsColumnName, containsRowName, getColIndexByName, getColName, getColNames, getRowIndexByName, getRowName, getRowNameMapIterator, getRowNames, hasColNames, hasMissingValues, hasRow, hasRowNames, numMissing, setColumnName, setColumnNames, setRowName, setRowNames
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface ubic.basecode.dataStructure.matrix.Matrix2D
addColumnName, asDoubles, assign, containsColumnName, containsRowName, getColIndexByName, getColName, getColNames, getRowIndexByName, getRowName, getRowNameMapIterator, getRowNames, hasColNames, hasRow, hasRowNames, numMissing, setColumnName, setColumnNames, setRowName, setRowNames
-
-
-
-
Method Detail
-
columns
public int columns()
Description copied from interface:Matrix2D
Get the number of columns the matrix has.
-
get
public Integer get(int row, int column)
- Parameters:
row
-column
-- Returns:
-
getColObj
public Integer[] getColObj(int col)
- Specified by:
getColObj
in interfacePrimitiveMatrix<R,C,Integer>
- Returns:
-
getColumn
public Integer[] getColumn(int col)
-
getEntry
public Integer getEntry(int row, int column)
-
getObject
public Integer getObject(int row, int col)
- Specified by:
getObject
in interfacePrimitiveMatrix<R,C,Integer>
- Returns:
-
getRow
public Integer[] getRow(int row)
-
getRowObj
public Integer[] getRowObj(int row)
- Specified by:
getRowObj
in interfacePrimitiveMatrix<R,C,Integer>
- Returns:
-
isMissing
public boolean isMissing(int i, int j)
Description copied from interface:Matrix2D
Check if the value at a given index is missing.
-
rows
public int rows()
Description copied from interface:Matrix2D
Get the number of rows the matrix has
-
set
public void set(int row, int column, Integer value)
-
setObj
public void setObj(int row, int column, Integer value)
- Parameters:
row
-column
-value
-
-
size
public int size()
- Specified by:
size
in classAbstractMatrix<R,C,Integer>
- Returns:
-
-