Package edu.cmu.tetrad.search.utils
Class KernelUtils
java.lang.Object
edu.cmu.tetrad.search.utils.KernelUtils
Provides various kernel utilities.
- Version:
- $Id: $Id
- Author:
- Robert Tillman
-
Method Summary
Modifier and TypeMethodDescriptionstatic Matrix
Constructs the centralized Gram matrix for a given vector valued sample.static Matrix
Constructs Gram matrix for a given vector valued sample.static Matrix
constructH
(int m) Constructs the projection matrix on 1/mstatic Matrix
incompleteCholeskyGramMatrix
(List<Kernel> kernels, DataSet dataset, List<Node> nodes, double precision) Approximates Gram matrix using incomplete Cholesky factorization
-
Method Details
-
constructGramMatrix
Constructs Gram matrix for a given vector valued sample. The set of kernels corresponds to the variables in the set. The output matrix is the tensor product of Gram matrices for each variable.- Parameters:
kernels
- the kernels for each variabledataset
- the dataset containing each variablenodes
- the variables to construct the Gram matrix for- Returns:
- a
Matrix
object
-
constructCentralizedGramMatrix
public static Matrix constructCentralizedGramMatrix(List<Kernel> kernels, DataSet dataset, List<Node> nodes) Constructs the centralized Gram matrix for a given vector valued sample. The set of kernels corresponds to the variables in the set. The output matrix is the tensor product of Gram matrices for each variable.- Parameters:
kernels
- the kernels for each variabledataset
- the dataset containing each variablenodes
- the variables to construct the Gram matrix for- Returns:
- a
Matrix
object
-
constructH
-
incompleteCholeskyGramMatrix
public static Matrix incompleteCholeskyGramMatrix(List<Kernel> kernels, DataSet dataset, List<Node> nodes, double precision) Approximates Gram matrix using incomplete Cholesky factorization- Parameters:
kernels
- the kernels for each variabledataset
- the dataset containing each variablenodes
- the variables to construct the Gram matrix forprecision
- a double- Returns:
- a
Matrix
object
-