Class CellBrowserTabularMatrixWriter
- java.lang.Object
-
- ubic.gemma.core.visualization.cellbrowser.CellBrowserTabularMatrixWriter
-
- All Implemented Interfaces:
ExpressionDataMatrixWriter<SingleCellExpressionDataMatrix<?>>,SingleCellExpressionDataMatrixWriter
public class CellBrowserTabularMatrixWriter extends Object implements SingleCellExpressionDataMatrixWriter
Generate a tabular matrix format compatible with Cell Browser.- Author:
- poirigui
-
-
Constructor Summary
Constructors Constructor Description CellBrowserTabularMatrixWriter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidsetAutoFlush(boolean autoFlush)Flush every time a complete line is written.voidsetScaleType(ScaleType scaleType)Set the scale type to use when writing the matrix.voidsetUseBioAssayIds(boolean useBioAssayIds)voidsetUseRawColumnNames(boolean useRawColumnNames)intwrite(Collection<SingleCellExpressionDataVector> vectors, Map<CompositeSequence,Set<Gene>> cs2gene, Writer writer)intwrite(Stream<SingleCellExpressionDataVector> vectors, Map<CompositeSequence,Set<Gene>> cs2gene, Writer writer)intwrite(SingleCellExpressionDataMatrix<?> matrix, Writer writer)Write the matrix to the given writer.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface ubic.gemma.core.datastructure.matrix.io.ExpressionDataMatrixWriter
write
-
-
-
-
Method Detail
-
setUseBioAssayIds
public void setUseBioAssayIds(boolean useBioAssayIds)
-
setUseRawColumnNames
public void setUseRawColumnNames(boolean useRawColumnNames)
-
setAutoFlush
public void setAutoFlush(boolean autoFlush)
Description copied from interface:ExpressionDataMatrixWriterFlush every time a complete line is written.This is not very efficient, but it can be used to view the output of a matrix as it is being written.
- Specified by:
setAutoFlushin interfaceExpressionDataMatrixWriter<SingleCellExpressionDataMatrix<?>>
-
setScaleType
public void setScaleType(@Nullable ScaleType scaleType)
Description copied from interface:ExpressionDataMatrixWriterSet the scale type to use when writing the matrix.When null, the original values must be used.
- Specified by:
setScaleTypein interfaceExpressionDataMatrixWriter<SingleCellExpressionDataMatrix<?>>
-
write
public int write(SingleCellExpressionDataMatrix<?> matrix, Writer writer) throws IOException, UnsupportedOperationException
Description copied from interface:ExpressionDataMatrixWriterWrite the matrix to the given writer.- Specified by:
writein interfaceExpressionDataMatrixWriter<SingleCellExpressionDataMatrix<?>>- Returns:
- the number of vectors written
- Throws:
UnsupportedOperationException- if the matrix cannot be written to a text output (i.e. if this is a binary format).IOException
-
write
public int write(Stream<SingleCellExpressionDataVector> vectors, @Nullable Map<CompositeSequence,Set<Gene>> cs2gene, Writer writer) throws IOException
- Throws:
IOException
-
write
public int write(Collection<SingleCellExpressionDataVector> vectors, @Nullable Map<CompositeSequence,Set<Gene>> cs2gene, Writer writer) throws IOException
- Throws:
IOException
-
-