Package adams.data.instancesanalysis.pls
Class MatrixHelper
- java.lang.Object
-
- weka.core.matrix.MatrixHelper
-
- adams.data.instancesanalysis.pls.MatrixHelper
-
public class MatrixHelper extends MatrixHelper
Helper class for the matrix-algorithm library.- Author:
- FracPete (fracpete at waikato dot ac dot nz)
-
-
Constructor Summary
Constructors Constructor Description MatrixHelper()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static weka.core.matrix.Matrix
jamaToWeka(Jama.Matrix jama)
Turns a Jama matrix into a Weka one.static weka.core.matrix.Matrix
matrixAlgoToWeka(com.github.waikatodatamining.matrix.core.Matrix matrixalgo)
Turns a matrix-algorithm matrix into a Weka one.static adams.data.spreadsheet.SpreadSheet
matrixToSpreadSheet(weka.core.matrix.Matrix matrix, String colPrefix)
Turns the matrix into a spreadsheet.static Jama.Matrix
wekaToJama(weka.core.matrix.Matrix weka)
Turns a Weka matrix into a Jama one.static com.github.waikatodatamining.matrix.core.Matrix
wekaToMatrixAlgo(weka.core.matrix.Matrix weka)
Turns a Weka matrix into a matrix-algorithm one.-
Methods inherited from class weka.core.matrix.MatrixHelper
columnAsVector, equal, equal, getAll, getDominantEigenVector, getVector, getX, getX, getY, getY, getY, normalizeVector, setVector, toInstances
-
-
-
-
Method Detail
-
jamaToWeka
public static weka.core.matrix.Matrix jamaToWeka(Jama.Matrix jama)
Turns a Jama matrix into a Weka one.- Parameters:
jama
- the jama matrix to convert- Returns:
- the converted matrix
-
wekaToJama
public static Jama.Matrix wekaToJama(weka.core.matrix.Matrix weka)
Turns a Weka matrix into a Jama one.- Parameters:
weka
- the Weka matrix to convert- Returns:
- the converted matrix
-
matrixAlgoToWeka
public static weka.core.matrix.Matrix matrixAlgoToWeka(com.github.waikatodatamining.matrix.core.Matrix matrixalgo)
Turns a matrix-algorithm matrix into a Weka one.- Parameters:
matrixalgo
- the jama matrix to convert- Returns:
- the converted matrix
-
wekaToMatrixAlgo
public static com.github.waikatodatamining.matrix.core.Matrix wekaToMatrixAlgo(weka.core.matrix.Matrix weka)
Turns a Weka matrix into a matrix-algorithm one.- Parameters:
weka
- the Weka matrix to convert- Returns:
- the converted matrix
-
matrixToSpreadSheet
public static adams.data.spreadsheet.SpreadSheet matrixToSpreadSheet(weka.core.matrix.Matrix matrix, String colPrefix)
Turns the matrix into a spreadsheet.- Parameters:
matrix
- the matrix to convertcolPrefix
- the prefix for the column names- Returns:
- the generated spreadsheet
-
-