Stan  2.14.0
probability, sampling & optimization
get_cdf_def.hpp
Go to the documentation of this file.
1 #ifndef STAN_LANG_AST_FUN_GET_CDF_DEF_HPP
2 #define STAN_LANG_AST_FUN_GET_CDF_DEF_HPP
3 
4 #include <stan/lang/ast.hpp>
5 #include <string>
6 
7 namespace stan {
8  namespace lang {
9 
10  std::string get_cdf(const std::string& dist_name) {
11  if (function_signatures::instance().has_key(dist_name + "_cdf_log"))
12  return dist_name + "_cdf_log";
13  else if (function_signatures::instance().has_key(dist_name + "_lcdf"))
14  return dist_name + "_lcdf";
15  else
16  return dist_name;
17  }
18 
19  }
20 }
21 #endif
Probability, optimization and sampling library.
static function_signatures & instance()
Return the instance of this singleton.
std::string get_cdf(const std::string &dist_name)
Return the name of the CDF for the specified distribution name.
Definition: get_cdf_def.hpp:10

     [ Stan Home Page ] © 2011–2016, Stan Development Team.