Formatter
cern.colt.matrix.objectalgo

Class Formatter

    • Constructor Detail

      • Formatter

        public Formatter()
        Constructs and returns a matrix formatter with alignment LEFT.
      • Formatter

        public Formatter(String alignment)
        Constructs and returns a matrix formatter.
        Parameters:
        alignment - the given alignment used to align a column.
    • Method Detail

      • toSourceCode

        public String toSourceCode(ObjectMatrix1D matrix)
        Returns a string s such that Object[] m = s is a legal Java statement.
        Parameters:
        matrix - the matrix to format.
      • toSourceCode

        public String toSourceCode(ObjectMatrix2D matrix)
        Returns a string s such that Object[] m = s is a legal Java statement.
        Parameters:
        matrix - the matrix to format.
      • toSourceCode

        public String toSourceCode(ObjectMatrix3D matrix)
        Returns a string s such that Object[] m = s is a legal Java statement.
        Parameters:
        matrix - the matrix to format.
      • toString

        public String toString(ObjectMatrix1D matrix)
        Returns a string representation of the given matrix.
        Parameters:
        matrix - the matrix to convert.
      • toString

        public String toString(ObjectMatrix2D matrix)
        Returns a string representation of the given matrix.
        Parameters:
        matrix - the matrix to convert.
      • toString

        public String toString(ObjectMatrix3D matrix)
        Returns a string representation of the given matrix.
        Parameters:
        matrix - the matrix to convert.
      • toTitleString

        public String toTitleString(ObjectMatrix2D matrix,                   String[] rowNames,                   String[] columnNames,                   String rowAxisName,                   String columnAxisName,                   String title)
        Returns a string representation of the given matrix with axis as well as rows and columns labeled.Pass null to one or more parameters to indicate that the corresponding decoration element shall not appear in the string converted matrix.
        Parameters:
        matrix - The matrix to format.
        rowNames - The headers of all rows (to be put to the left of the matrix).
        columnNames - The headers of all columns (to be put to above the matrix).
        rowAxisName - The label of the y-axis.
        columnAxisName - The label of the x-axis.
        title - The overall title of the matrix to be formatted.
        Returns:
        the matrix converted to a string.
      • toTitleString

        public String toTitleString(ObjectMatrix3D matrix,                   String[] sliceNames,                   String[] rowNames,                   String[] columnNames,                   String sliceAxisName,                   String rowAxisName,                   String columnAxisName,                   String title)
        Returns a string representation of the given matrix with axis as well as rows and columns labeled.Pass null to one or more parameters to indicate that the corresponding decoration element shall not appear in the string converted matrix.
        Parameters:
        matrix - The matrix to format.
        sliceNames - The headers of all slices (to be put above each slice).
        rowNames - The headers of all rows (to be put to the left of the matrix).
        columnNames - The headers of all columns (to be put to above the matrix).
        sliceAxisName - The label of the z-axis (to be put above each slice).
        rowAxisName - The label of the y-axis.
        columnAxisName - The label of the x-axis.
        title - The overall title of the matrix to be formatted.
        Returns:
        the matrix converted to a string.

SCaVis 2.1 © jWork.ORG