1 #ifndef STAN__MATH__MATRIX__TAIL_HPP
2 #define STAN__MATH__MATRIX__TAIL_HPP
21 Eigen::Matrix<T,Eigen::Dynamic,1>
22 tail(
const Eigen::Matrix<T,Eigen::Dynamic,1>& v,
36 Eigen::Matrix<T,1,Eigen::Dynamic>
37 tail(
const Eigen::Matrix<T,1,Eigen::Dynamic>& rv,
45 std::vector<T>
tail(
const std::vector<T>& sv,
51 for (idx_t i = sv.size() - n; i < sv.size(); ++i)
bool check_std_vector_index(const char *function, size_t i, const std::vector< T_y > &y, const char *name, T_result *result)
Return true if the specified index is valid in std vector.
bool check_column_index(const char *function, size_t i, const Eigen::Matrix< T_y, R, C > &y, const char *name, T_result *result)
Return true if the specified index is a valid column of the matrix.
Primary template class for the metaprogram to compute the index type of a container.
Eigen::Matrix< T, Eigen::Dynamic, 1 > tail(const Eigen::Matrix< T, Eigen::Dynamic, 1 > &v, size_t n)
Return the specified number of elements as a vector from the back of the specified vector...
bool check_row_index(const char *function, size_t i, const Eigen::Matrix< T_y, R, C > &y, const char *name, T_result *result)
Return true if the specified index is a valid row of the matrix.