Interface Matrix3D<R,C,S,V>
-
- All Known Implementing Classes:
AbstractMatrix3D,DenseDouble3dMatrix,DenseObject3DMatrix,DoubleMatrix3D
public interface Matrix3D<R,C,S,V>- Author:
- ?
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidaddColumnName(C s, int index)Add a column name associated with an index.voidaddRowName(R s, int index)Add a row name associated with a row index.voidaddSliceName(S s, int index)Add a slice nameintcolumns()Get the number of columns the matrix has.booleancontainsColumnName(C columnName)Check if the matrix contains a column namebooleancontainsRowName(R rowName)Check if the matrix contains a row namebooleancontainsSliceName(S sliceName)Check if the matrix contains a slice nameintgetColIndexByName(C s)Get the index of a column by name.CgetColName(int i)Get the column name for an index.Iterator<C>getColNameIterator()List<C>getColNames()VgetObject(int slice, int row, int column)intgetRowIndexByName(R s)Get the index of a row by name.RgetRowName(int i)Get the row name for an indexIterator<R>getRowNameIterator()List<R>getRowNames()intgetSliceIndexByName(S s)Get a slice indexSgetSliceName(int i)Get a slice nameIterator<S>getSliceNameIterator()List<S>getSliceNames()booleanhasColNames()Check if this matrix has a valid set of column names.booleanhasRow(R r)booleanhasRowNames()booleanhasSliceNames()booleanisMissing(int slice, int row, int column)Check if the value at a given index is missing.intnumMissing()Return the number of missing values in the matrix.introws()Get the number of rows the matrix hasvoidsetColumnNames(List<C> v)voidsetRowNames(List<R> v)voidsetSliceNames(List<S> v)intslices()
-
-
-
Method Detail
-
addColumnName
void addColumnName(C s, int index)
Add a column name associated with an index.- Parameters:
s- a column nameindex- int the column index associated with this name
-
addRowName
void addRowName(R s, int index)
Add a row name associated with a row index.- Parameters:
s- row nameindex-
-
addSliceName
void addSliceName(S s, int index)
Add a slice name- Parameters:
s- name of the sliceindex-
-
columns
int columns()
Get the number of columns the matrix has.- Returns:
- int
-
containsColumnName
boolean containsColumnName(C columnName)
Check if the matrix contains a column name- Parameters:
colName-- Returns:
- true if the matrix contains the column name
-
containsRowName
boolean containsRowName(R rowName)
Check if the matrix contains a row name- Parameters:
rowName-- Returns:
- true if the matrix contains the row name
-
containsSliceName
boolean containsSliceName(S sliceName)
Check if the matrix contains a slice name- Parameters:
stripeName-- Returns:
- true if the matrix contains the slice name
-
getColIndexByName
int getColIndexByName(C s)
Get the index of a column by name.- Parameters:
s- name- Returns:
- column index
-
getColName
C getColName(int i)
Get the column name for an index.- Parameters:
i- column index- Returns:
- column name
-
getObject
V getObject(int slice, int row, int column)
-
getRowIndexByName
int getRowIndexByName(R s)
Get the index of a row by name.- Parameters:
s- name- Returns:
- row index
-
getRowName
R getRowName(int i)
Get the row name for an index- Parameters:
i- row index- Returns:
- name of the row
-
getSliceIndexByName
int getSliceIndexByName(S s)
Get a slice index- Parameters:
s- name- Returns:
- slice index
-
getSliceName
S getSliceName(int i)
Get a slice name- Parameters:
i- index- Returns:
- slice name
-
hasColNames
boolean hasColNames()
Check if this matrix has a valid set of column names.- Returns:
- boolean
-
hasRow
boolean hasRow(R r)
- Parameters:
r- row name- Returns:
- whether the row exists
-
hasRowNames
boolean hasRowNames()
- Returns:
- boolean
-
hasSliceNames
boolean hasSliceNames()
-
isMissing
boolean isMissing(int slice, int row, int column)Check if the value at a given index is missing.- Parameters:
slice-row-column-- Returns:
- true if the value is missing, false otherwise.
-
numMissing
int numMissing()
Return the number of missing values in the matrix.- Returns:
- number missing
-
rows
int rows()
Get the number of rows the matrix has- Returns:
- int
-
slices
int slices()
-
-