1 #ifndef STAN__MATH__ERROR_HANDLING__MATRIX__CHECK_VECTOR_HPP
2 #define STAN__MATH__ERROR_HANDLING__MATRIX__CHECK_VECTOR_HPP
13 template <
typename T,
int R,
int C,
typename T_result>
15 const Eigen::Matrix<T,R,C>& x,
18 if (x.rows() == 1 || x.cols() == 1)
21 std::ostringstream msg;
22 msg << name <<
" (%1%) has " << x.rows() <<
" rows and "
23 << x.cols() <<
" columns but it should be a vector so it should either have 1 row or 1 column";
24 std::string tmp(msg.str());
bool dom_err(const char *function, const T &y, const char *name, const char *error_msg, const T_msg error_msg2, T_result *result)
bool check_vector(const char *function, const Eigen::Matrix< T, R, C > &x, const char *name, T_result *result)
scalar_type_helper< is_vector< T >::value, T >::type type