1#ifndef STAN_MATH_PRIM_FUN_COL_HPP
2#define STAN_MATH_PRIM_FUN_COL_HPP
24template <
typename T, require_matrix_t<T>* =
nullptr>
25inline auto col(T&& m,
size_t j) {
27 return make_holder([j](
auto&& m_) {
return m_.col(j - 1); },
auto col(T_x &&x, size_t j)
Return the specified column of the specified kernel generator expression using start-at-1 indexing.
auto make_holder(F &&func, Args &&... args)
Calls given function with given arguments.
void check_column_index(const char *function, const char *name, const T_y &y, size_t i)
Check if the specified index is a valid column of the matrix.
The lgamma implementation in stan-math is based on either the reentrant safe lgamma_r implementation ...