|
Rcpp Version 0.9.10
|

Go to the source code of this file.
Defines | |
| #define | give_log log_p |
| #define | R_D__0 (log_p ? ML_NEGINF : 0.) |
| #define | R_D__1 (log_p ? 0. : 1.) |
| #define | R_DT_0 (lower_tail ? R_D__0 : R_D__1) |
| #define | R_DT_1 (lower_tail ? R_D__1 : R_D__0) |
| #define | R_D_Lval(p) (lower_tail ? (p) : (0.5 - (p) + 0.5)) |
| #define | R_D_Cval(p) (lower_tail ? (0.5 - (p) + 0.5) : (p)) |
| #define | R_D_val(x) (log_p ? ::log(x) : (x)) |
| #define | R_D_qIv(p) (log_p ? ::exp(p) : (p)) |
| #define | R_D_exp(x) (log_p ? (x) : ::exp(x)) |
| #define | R_D_log(p) (log_p ? (p) : ::log(p)) |
| #define | R_D_Clog(p) (log_p ? ::log1p(-(p)) : (0.5 - (p) + 0.5)) |
| #define | R_Log1_Exp(x) ((x) > -M_LN2 ? ::log(-::expm1(x)) : ::log1p(-::exp(x))) |
| #define | R_D_LExp(x) (log_p ? R_Log1_Exp(x) : ::log1p(-x)) |
| #define | R_DT_val(x) (lower_tail ? R_D_val(x) : R_D_Clog(x)) |
| #define | R_DT_Cval(x) (lower_tail ? R_D_Clog(x) : R_D_val(x)) |
| #define | R_DT_qIv(p) |
| #define | R_DT_CIv(p) |
| #define | R_DT_exp(x) R_D_exp(R_D_Lval(x)) |
| #define | R_DT_Cexp(x) R_D_exp(R_D_Cval(x)) |
| #define | R_DT_log(p) (lower_tail? R_D_log(p) : R_D_LExp(p)) |
| #define | R_DT_Clog(p) (lower_tail? R_D_LExp(p): R_D_log(p)) |
| #define | R_DT_Log(p) (lower_tail? (p) : R_Log1_Exp(p)) |
| #define | R_Q_P01_check(p) |
| #define | R_Q_P01_boundaries(p, _LEFT_, _RIGHT_) |
| #define | R_P_bounds_01(x, x_min, x_max) |
| #define | R_P_bounds_Inf_01(x) |
| #define | R_D_fexp(f, x) (give_log ? -0.5*log(f)+(x) : exp(x)/sqrt(f)) |
| #define | R_D_forceint(x) floor((x) + 0.5) |
| #define | R_D_nonint(x) (fabs((x) - floor((x)+0.5)) > 1e-7) |
| #define | R_D_negInonint(x) (x < 0. || R_D_nonint(x)) |
| #define | R_D_nonint_check(x) |
| #define R_D__0 (log_p ? ML_NEGINF : 0.) |
Definition at line 27 of file macros.h.
Referenced by Rcpp::stats::d_exp_0(), Rcpp::stats::dgamma_1(), Rcpp::stats::dlnorm_0(), Rcpp::stats::dlnorm_1(), Rcpp::stats::dnorm_0(), Rcpp::stats::dnorm_1(), Rcpp::stats::dunif_0(), and Rcpp::stats::dweibull_1().
Definition at line 38 of file macros.h.
Referenced by Rcpp::stats::p_exp_0(), and Rcpp::stats::pweibull_1().
| #define R_D_nonint_check | ( | x | ) |
Definition at line 36 of file macros.h.
Referenced by Rcpp::stats::punif_0().
| #define R_DT_0 (lower_tail ? R_D__0 : R_D__1) |
Definition at line 29 of file macros.h.
Referenced by Rcpp::stats::p_exp_0(), Rcpp::stats::plnorm_0(), Rcpp::stats::plnorm_1(), Rcpp::stats::pnorm_0(), Rcpp::stats::pnorm_1(), Rcpp::stats::punif_0(), Rcpp::stats::pweibull_1(), and Rcpp::stats::q_exp_0().
| #define R_DT_1 (lower_tail ? R_D__1 : R_D__0) |
Definition at line 30 of file macros.h.
Referenced by Rcpp::stats::pnorm_0(), Rcpp::stats::pnorm_1(), and Rcpp::stats::punif_0().
| #define R_DT_CIv | ( | p | ) |
Definition at line 63 of file macros.h.
Referenced by Rcpp::stats::q_exp_0(), and Rcpp::stats::qweibull_1().
| #define R_DT_qIv | ( | p | ) |
Definition at line 52 of file macros.h.
Referenced by Rcpp::stats::qunif_0(), and Rcpp::stats::qunif_1().
| #define R_P_bounds_01 | ( | x, | |
| x_min, | |||
| x_max | |||
| ) |
| #define R_P_bounds_Inf_01 | ( | x | ) |
Definition at line 107 of file macros.h.
Referenced by Rcpp::stats::plogis_0(), and Rcpp::stats::plogis_1().
| #define R_Q_P01_boundaries | ( | p, | |
| _LEFT_, | |||
| _RIGHT_ | |||
| ) |
if (log_p) { \ if(p > 0) \ return R_NaN ; \ if(p == 0) /* upper bound*/ \ return lower_tail ? _RIGHT_ : _LEFT_; \ if(p == ML_NEGINF) \ return lower_tail ? _LEFT_ : _RIGHT_; \ } \ else { /* !log_p */ \ if(p < 0 || p > 1) \ return R_NaN ; \ if(p == 0) \ return lower_tail ? _LEFT_ : _RIGHT_; \ if(p == 1) \ return lower_tail ? _RIGHT_ : _LEFT_; \ }
Definition at line 84 of file macros.h.
Referenced by Rcpp::stats::qlnorm_0(), Rcpp::stats::qlnorm_1(), Rcpp::stats::qlogis_0(), Rcpp::stats::qlogis_1(), and Rcpp::stats::qweibull_1().
| #define R_Q_P01_check | ( | p | ) |
if ((log_p && p > 0) || \ (!log_p && (p < 0 || p > 1)) ) \ return R_NaN
Definition at line 68 of file macros.h.
Referenced by Rcpp::stats::qunif_0(), and Rcpp::stats::qunif_1().