Class AbstractBulkExpressionDataMatrix<T>
java.lang.Object
ubic.gemma.core.datastructure.matrix.AbstractExpressionDataMatrix<T>
ubic.gemma.core.datastructure.matrix.AbstractBulkExpressionDataMatrix<T>
- Type Parameters:
T-
- All Implemented Interfaces:
BulkExpressionDataMatrix<T>,ExpressionDataMatrix<T>
- Direct Known Subclasses:
BulkExpressionDataDoubleMatrix,BulkExpressionDataIntMatrix,EmptyBulkExpressionDataMatrix
public abstract class AbstractBulkExpressionDataMatrix<T>
extends AbstractExpressionDataMatrix<T>
implements BulkExpressionDataMatrix<T>
Base class for bulk expression data matrices.
If you need to handle multiple BioAssay per BioMaterial, use AbstractMultiAssayExpressionDataMatrix
instead.
- Author:
- poirigui
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedAbstractBulkExpressionDataMatrix(List<? extends BulkExpressionDataVector> vectors) protectedAbstractBulkExpressionDataMatrix(ExpressionExperiment expressionExperiment, BioAssayDimension dimension, QuantitationType quantitationType, List<CompositeSequence> designElements) -
Method Summary
Modifier and TypeMethodDescriptionintcolumns()Obtain the total number of columns.get(CompositeSequence designElement, BioAssay bioAssay) Access a single value of the matrix.Obtain the dimension for the columns of this matrix.getBioAssayForColumn(int index) Obtain an assay corresponding to a given column.getBioMaterialForColumn(int index) Obtain a biomaterial corresponding to a column.T[]Access a single column of the matrix.intgetColumnIndex(BioAssay bioAssay) intgetColumnIndex(BioMaterial bioMaterial) protected StringgetColumnLabel(int j) Obtain a label suitable for describing a column of the matrix.getDesignElementForRow(int index) Return a design element for a given index.Obtain all the design elements in this data matrix.Return the expression experiment this matrix is holding data for, if known.Obtain the quantitation type for this matrix.T[]getRow(CompositeSequence designElement) Return a row that 'came from' the given design element.getRowElement(int row) intgetRowIndex(CompositeSequence designElement) int[]getRowIndices(CompositeSequence designElement) Obtain all the rows that correspond to the given design element, ornullif the design element is not found.protected StringgetRowLabel(int i) Obtain a label suitable for describing a row of the matrix.introws()Methods inherited from class ubic.gemma.core.datastructure.matrix.AbstractExpressionDataMatrix
format, format, format, formatRepresentation, toStringMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface ubic.gemma.core.datastructure.matrix.BulkExpressionDataMatrix
getRawMatrix, hasMissingValuesMethods inherited from interface ubic.gemma.core.datastructure.matrix.ExpressionDataMatrix
get, getColumn, getRow, sliceRows
-
Constructor Details
-
AbstractBulkExpressionDataMatrix
protected AbstractBulkExpressionDataMatrix(@Nullable ExpressionExperiment expressionExperiment, BioAssayDimension dimension, QuantitationType quantitationType, List<CompositeSequence> designElements) -
AbstractBulkExpressionDataMatrix
-
-
Method Details
-
getExpressionExperiment
Description copied from interface:ExpressionDataMatrixReturn the expression experiment this matrix is holding data for, if known.- Specified by:
getExpressionExperimentin interfaceExpressionDataMatrix<T>
-
getQuantitationType
Description copied from interface:ExpressionDataMatrixObtain the quantitation type for this matrix.- Specified by:
getQuantitationTypein interfaceExpressionDataMatrix<T>
-
getBioAssayDimension
Description copied from interface:BulkExpressionDataMatrixObtain the dimension for the columns of this matrix.- Specified by:
getBioAssayDimensionin interfaceBulkExpressionDataMatrix<T>
-
columns
public int columns()Description copied from interface:ExpressionDataMatrixObtain the total number of columns.- Specified by:
columnsin interfaceExpressionDataMatrix<T>
-
getColumn
Description copied from interface:BulkExpressionDataMatrixAccess a single column of the matrix.- Specified by:
getColumnin interfaceBulkExpressionDataMatrix<T>- Returns:
- a vector for the given column, or null if the column is not present
-
getColumnIndex
- Specified by:
getColumnIndexin interfaceBulkExpressionDataMatrix<T>- Returns:
- the index of the column for the data for the bioAssay, or -1 if missing
-
getColumnIndex
- Specified by:
getColumnIndexin interfaceBulkExpressionDataMatrix<T>
-
getBioAssayForColumn
Description copied from interface:BulkExpressionDataMatrixObtain an assay corresponding to a given column.- Specified by:
getBioAssayForColumnin interfaceBulkExpressionDataMatrix<T>
-
getBioMaterialForColumn
Description copied from interface:BulkExpressionDataMatrixObtain a biomaterial corresponding to a column.- Specified by:
getBioMaterialForColumnin interfaceBulkExpressionDataMatrix<T>
-
rows
public int rows()- Specified by:
rowsin interfaceExpressionDataMatrix<T>- Returns:
- int
-
getRow
Description copied from interface:ExpressionDataMatrixReturn a row that 'came from' the given design element.- Specified by:
getRowin interfaceExpressionDataMatrix<T>- Parameters:
designElement- de- Returns:
- the corresponding row or null if the design element is not found in the matrix
-
getRowIndex
- Specified by:
getRowIndexin interfaceExpressionDataMatrix<T>- Returns:
- the index for the given design element, or -1 if not found
-
getRowIndices
Description copied from interface:ExpressionDataMatrixObtain all the rows that correspond to the given design element, ornullif the design element is not found.- Specified by:
getRowIndicesin interfaceExpressionDataMatrix<T>
-
getDesignElements
Description copied from interface:ExpressionDataMatrixObtain all the design elements in this data matrix.- Specified by:
getDesignElementsin interfaceExpressionDataMatrix<T>
-
getDesignElementForRow
Description copied from interface:ExpressionDataMatrixReturn a design element for a given index.- Specified by:
getDesignElementForRowin interfaceExpressionDataMatrix<T>
-
get
Description copied from interface:BulkExpressionDataMatrixAccess a single value of the matrix. Note that because there can be multiple bioassays per column and multiple design elements per row, it is possible for this method to retrieve a data that does not come from the bioassay and/or designelement arguments.- Specified by:
getin interfaceBulkExpressionDataMatrix<T>- Parameters:
designElement- debioAssay- ba- Returns:
- the value at the given design element and bioassay, or
nullif the value is missing
-
getRowElements
- Specified by:
getRowElementsin interfaceExpressionDataMatrix<T>- Returns:
- list of elements representing the row 'labels'.
-
getRowElement
- Specified by:
getRowElementin interfaceExpressionDataMatrix<T>
-
getRowLabel
Description copied from class:AbstractExpressionDataMatrixObtain a label suitable for describing a row of the matrix.- Specified by:
getRowLabelin classAbstractExpressionDataMatrix<T>
-
getColumnLabel
Description copied from class:AbstractExpressionDataMatrixObtain a label suitable for describing a column of the matrix.- Specified by:
getColumnLabelin classAbstractExpressionDataMatrix<T>
-