public class Dataset extends Object
| Constructor and Description |
|---|
Dataset(float[][] matrix) |
Dataset(int rows,
int cols) |
| Modifier and Type | Method and Description |
|---|---|
void |
addValueToMatrix(int row,
int coll,
float value) |
void |
addValueToMatrix(int row,
int coll,
String value) |
boolean |
containsNonZeroValues()
Returns false if this dataset only contains zero's.
|
ByteArrayOutputStream |
exportAsCSV() |
void |
flipRowCols() |
List<String> |
getColLabels() |
List<Map<String,String>> |
getColLabelsAttrs() |
String |
getColTitle() |
String |
getFormat() |
String[][] |
getMatrix() |
int |
getNbCols() |
int |
getNbRows() |
List<String> |
getRowLabels() |
List<Map<String,String>> |
getRowLabelsAttrs() |
String |
getRowTitle() |
void |
setColLabel(int n,
String label) |
void |
setColLabelAttr(int pos,
Map<String,String> attrMap) |
void |
setColLabelAttr(int pos,
String attrName,
String attr) |
void |
setColTitle(String colTitle) |
void |
setFormat(String format) |
void |
setRowLabel(int n,
String label) |
void |
setRowLabelAttr(int pos,
Map<String,String> attrMap) |
void |
setRowLabelAttr(int pos,
String attrName,
String attr) |
void |
setRowTitle(String rowTitle) |
public Dataset(int rows,
int cols)
public Dataset(float[][] matrix)
public void setColLabel(int n,
String label)
public void setRowLabel(int n,
String label)
public String getRowTitle()
public String getColTitle()
public void setColTitle(String colTitle)
public void setRowTitle(String rowTitle)
public int getNbRows()
public int getNbCols()
public String getFormat()
public void setFormat(String format)
public String[][] getMatrix()
public void addValueToMatrix(int row,
int coll,
float value)
public void addValueToMatrix(int row,
int coll,
String value)
throws ParseException
ParseExceptionpublic boolean containsNonZeroValues()
public void flipRowCols()
public ByteArrayOutputStream exportAsCSV() throws IOException
IOExceptionCopyright © 2014 DuraSpace. All Rights Reserved.