1 #ifndef STAN_MATH_PRIM_MAT_FUN_MAKE_NU_HPP 2 #define STAN_MATH_PRIM_MAT_FUN_MAKE_NU_HPP 18 Eigen::Array<T, Eigen::Dynamic, 1>
make_nu(
const T& eta,
size_t K) {
26 Array<T, Dynamic, 1> nu(K * (K - 1) / 2);
27 T alpha = eta + 0.5 * (K - 2.0);
28 T alpha2 = 2.0 * alpha;
29 for (size_type j = 0; j < (K - 1); ++j)
31 size_t counter = K - 1;
32 for (size_type i = 1; i < (K - 1); ++i) {
35 for (size_type j = i + 1; j < K; ++j, ++counter)
Eigen::Matrix< double, Eigen::Dynamic, Eigen::Dynamic >::Index size_type
Type for sizes and indexes in an Eigen matrix with double e.
Primary template class for the metaprogram to compute the index type of a container.
Eigen::Array< T, Eigen::Dynamic, 1 > make_nu(const T &eta, size_t K)
Return the degrees of freedom for the t distribution that corresponds to the shape parameter in the L...