ptriangle            package:rotRPackage            R Documentation

_C_u_m_u_l_a_t_i_v_e _D_i_s_t_r_i_b_u_t_i_o_n _F_u_n_c_t_i_o_n _o_f _a _t_r_i_a_n_g_u_l_a_r _d_i_s_t_r_i_b_u_t_i_o_n

_D_e_s_c_r_i_p_t_i_o_n:

     This function computes the CDF of the triangular distribution over
     the given input vector.

_U_s_a_g_e:

     ptriangle(x, a=0, m=0.5, b=1)

_A_r_g_u_m_e_n_t_s:

       x: Point(s) where the CDF is computed, vector

       a: The lower bound of the Triangular distribution, real.

       m: The most likely value of the Triangular distribution, real, a
          <= m <= b.

       b: The upper bound of the Triangular distribution, real, b > a

_D_e_t_a_i_l_s:

     The triangular distribution has the following density function: $$
     f(x, a, m, b) = 2 (x - a) / ((m - a)(b - a)) if a <= x <= m  f(x,
     a, m, b) = 2 (b - x) / ((b - m)(b - a)) if m <  x <= b  $$

_V_a_l_u_e:

     The CDF value(s), vector

_A_u_t_h_o_r(_s):

     Pierre-Matthieu Pair, Rgis Lebrun.

_E_x_a_m_p_l_e_s:

     # Standard Triangular distribution example. 

     x <- (1000) * 8 
     plot(x, ptriangle(x, 1, 3, 7))

