![]() |
Stan Math Library
5.0.0
Automatic Differentiation
|
Eigen::Matrix< value_type_t< T_CPCs >, Eigen::Dynamic, Eigen::Dynamic > stan::math::read_corr_matrix | ( | const T_CPCs & | CPCs, |
size_t | K, | ||
Lp & | log_prob | ||
) |
Return the correlation matrix of the specified dimensionality corresponding to the specified canonical partial correlations, incrementing the specified scalar reference with the log absolute determinant of the Jacobian of the transformation.
It is usually preferable to utilize the version that returns the Cholesky factor of the correlation matrix rather than the correlation matrix itself in statistical calculations.
T_CPCs | type of the array (must be derived from Eigen::ArrayBase and have one compile-time dimension equal to 1) |
Lp | A scalar type for the lp argument. The scalar type of T_CPCs should be convertable to this. |
CPCs | The (K choose 2) canonical partial correlations in (-1, 1). |
K | Dimensionality of correlation matrix. |
log_prob | Reference to variable to increment with the log Jacobian determinant. |
Definition at line 60 of file read_corr_matrix.hpp.