📄 matrix.html
字号:
<BR> Sets a row of the matrix to the given row.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../weka/core/Matrix.html#solve(double[])">solve</A></B>(double[] bb)</CODE><BR> Solve A*X = B using backward substitution.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> boolean</CODE></FONT></TD><TD><CODE><B><A HREF="../../weka/core/Matrix.html#testEigen(weka.core.Matrix, double[], boolean)">testEigen</A></B>(<A HREF="../../weka/core/Matrix.html" title="class in weka.core">Matrix</A> V, double[] d, boolean verbose)</CODE><BR> Test eigenvectors and eigenvalues.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> java.lang.String</CODE></FONT></TD><TD><CODE><B><A HREF="../../weka/core/Matrix.html#toString()">toString</A></B>()</CODE><BR> Converts a matrix to a string</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> <A HREF="../../weka/core/Matrix.html" title="class in weka.core">Matrix</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../weka/core/Matrix.html#transpose()">transpose</A></B>()</CODE><BR> Returns the transpose of a matrix.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../weka/core/Matrix.html#write(java.io.Writer)">write</A></B>(java.io.Writer w)</CODE><BR> Writes out a matrix.</TD></TR></TABLE> <A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor"><TD><B>Methods inherited from class java.lang.Object</B></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE>equals, getClass, hashCode, notify, notifyAll, wait, wait, wait</CODE></TD></TR></TABLE> <P><!-- ============ FIELD DETAIL =========== --><!-- ========= CONSTRUCTOR DETAIL ======== --><A NAME="constructor_detail"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=1><FONT SIZE="+2"><B>Constructor Detail</B></FONT></TD></TR></TABLE><A NAME="Matrix(int, int)"><!-- --></A><H3>Matrix</H3><PRE>public <B>Matrix</B>(int nr, int nc)</PRE><DL><DD>Constructs a matrix and initializes it with default values.<P><DT><B>Parameters:</B><DD><CODE>nr</CODE> - the number of rows<DD><CODE>nc</CODE> - the number of columns</DL><HR><A NAME="Matrix(double[][])"><!-- --></A><H3>Matrix</H3><PRE>public <B>Matrix</B>(double[][] array) throws java.lang.Exception</PRE><DL><DD>Constructs a matrix using a given array.<P><DT><B>Parameters:</B><DD><CODE>array</CODE> - the values of the matrix</DL><HR><A NAME="Matrix(java.io.Reader)"><!-- --></A><H3>Matrix</H3><PRE>public <B>Matrix</B>(java.io.Reader r) throws java.lang.Exception</PRE><DL><DD>Reads a matrix from a reader. The first line in the file should contain the number of rows and columns. Subsequent lines contain elements of the matrix.<P><DT><B>Parameters:</B><DD><CODE>r</CODE> - the reader containing the matrix<DT><B>Throws:</B><DD><CODE>java.lang.Exception</CODE> - if an error occurs</DL><!-- ============ METHOD DETAIL ========== --><A NAME="method_detail"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=1><FONT SIZE="+2"><B>Method Detail</B></FONT></TD></TR></TABLE><A NAME="clone()"><!-- --></A><H3>clone</H3><PRE>public java.lang.Object <B>clone</B>() throws java.lang.CloneNotSupportedException</PRE><DL><DD>Creates and returns a clone of this object.<P><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>a clone of this instance.<DT><B>Throws:</B><DD><CODE>java.lang.CloneNotSupportedException</CODE> - if an error occurs</DL></DD></DL><HR><A NAME="write(java.io.Writer)"><!-- --></A><H3>write</H3><PRE>public void <B>write</B>(java.io.Writer w) throws java.lang.Exception</PRE><DL><DD>Writes out a matrix.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>w</CODE> - the output Writer<DT><B>Throws:</B><DD><CODE>java.lang.Exception</CODE> - if an error occurs</DL></DD></DL><HR><A NAME="getElement(int, int)"><!-- --></A><H3>getElement</H3><PRE>public final double <B>getElement</B>(int rowIndex, int columnIndex)</PRE><DL><DD>Returns the value of a cell in the matrix.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>rowIndex</CODE> - the row's index<DD><CODE>columnIndex</CODE> - the column's index<DT><B>Returns:</B><DD>the value of the cell of the matrix</DL></DD></DL><HR><A NAME="addElement(int, int, double)"><!-- --></A><H3>addElement</H3><PRE>public final void <B>addElement</B>(int rowIndex, int columnIndex, double value)</PRE><DL><DD>Add a value to an element.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>rowIndex</CODE> - the row's index.<DD><CODE>columnIndex</CODE> - the column's index.<DD><CODE>value</CODE> - the value to add.</DL></DD></DL><HR><A NAME="numRows()"><!-- --></A><H3>numRows</H3><PRE>public final int <B>numRows</B>()</PRE><DL><DD>Returns the number of rows in the matrix.<P><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>the number of rows</DL></DD></DL><HR><A NAME="numColumns()"><!-- --></A><H3>numColumns</H3><PRE>public final int <B>numColumns</B>()</PRE><DL><DD>Returns the number of columns in the matrix.<P><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>the number of columns</DL></DD></DL><HR><A NAME="setElement(int, int, double)"><!-- --></A><H3>setElement</H3><PRE>public final void <B>setElement</B>(int rowIndex, int columnIndex, double value)</PRE><DL><DD>Sets an element of the matrix to the given value.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>rowIndex</CODE> - the row's index<DD><CODE>columnIndex</CODE> - the column's index<DD><CODE>value</CODE> - the value</DL></DD></DL><HR><A NAME="setRow(int, double[])"><!-- --></A><H3>setRow</H3><PRE>public final void <B>setRow</B>(int index, double[] newRow)</PRE><DL><DD>Sets a row of the matrix to the given row. Performs a deep copy.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>index</CODE> - the row's index<DD><CODE>newRow</CODE> - an array of doubles</DL></DD></DL><HR><A NAME="getRow(int)"><!-- --></A><H3>getRow</H3><PRE>public double[] <B>getRow</B>(int index)</PRE><DL><DD>Gets a row of the matrix and returns it as double array.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>index</CODE> - the row's index<DT><B>Returns:</B><DD>an array of doubles</DL></DD></DL><HR><A NAME="getColumn(int)"><!-- --></A><H3>getColumn</H3><PRE>public double[] <B>getColumn</B>(int index)</PRE><DL><DD>Gets a column of the matrix and returns it as a double array.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>index</CODE> - the column's index<DT><B>Returns:</B><DD>an array of doubles</DL></DD></DL><HR><A NAME="setColumn(int, double[])"><!-- --></A><H3>setColumn</H3><PRE>public final void <B>setColumn</B>(int index, double[] newColumn)</PRE><DL><DD>Sets a column of the matrix to the given column. Performs a deep copy.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>index</CODE> - the column's index<DD><CODE>newColumn</CODE> - an array of doubles</DL></DD></DL><HR><A NAME="toString()"><!-- --></A><H3>toString</H3><PRE>public java.lang.String <B>toString</B>()</PRE><DL><DD>Converts a matrix to a string<P><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>the converted string</DL></DD></DL>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -