Package edu.cmu.tetrad.data
Interface Covariances
public interface Covariances
Some comemon methods for the various covariance implementations.
- Author:
- Joseph D. Ramsey
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptiondouble
covariance
(int i, int j) Returns the covariance at (i, j).double[][]
Returns the underlying covariance matrix.double[][]
getSubMatrix
(int[] rows, int[] cols) Returns a submatrix of the covariance matrix for the given rows and columns.void
setCovariance
(int i, int j, double v) Sets the covariance at (i, j) to a particular value.int
size()
Returns the dimensiom of the matrix.
-
Field Details
-
serialVersionUID
static final long serialVersionUID- See Also:
-
-
Method Details
-
covariance
double covariance(int i, int j) Returns the covariance at (i, j). -
size
int size()Returns the dimensiom of the matrix. -
setCovariance
void setCovariance(int i, int j, double v) Sets the covariance at (i, j) to a particular value. Not effective for implemetations that calculate covariances from data on the fly. -
getMatrix
double[][] getMatrix()Returns the underlying covariance matrix. -
getSubMatrix
double[][] getSubMatrix(int[] rows, int[] cols) Returns a submatrix of the covariance matrix for the given rows and columns.
-