Unif-class               package:distr               R Documentation

_C_l_a_s_s "_U_n_i_f"

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

     The uniform distribution has density

                          d(x) = 1/(max-min)

     for min, by default =0, <= x <= max, by default =1. C.f. 'runif'

_O_b_j_e_c_t_s _f_r_o_m _t_h_e _C_l_a_s_s:

     Objects can be created by calls of the form 'Unif(Min, Max)'. This
     object is a uniform distribution.

_S_l_o_t_s:

     '_i_m_g': Object of class '"Reals"': The space of the image of this
          distribution has got dimension 1 and the name "Real Space". 

     '_p_a_r_a_m': Object of class '"UnifParameter"': the parameter of this
          distribution (Min and Max), declared at its instantiation 

     '_r': Object of class '"function"': generates random numbers (calls
          function 'runif')

     '_d': Object of class '"function"': density function (calls
          function 'dunif')

     '_p': Object of class '"function"': cumulative function (calls
          function 'punif')

     '_q': Object of class '"function"': inverse of the cumulative
          function (calls function 'qunif')

_E_x_t_e_n_d_s:

     Class '"AbscontDistribution"', directly.
      Class '"UnivariateDistribution"', by class
     '"AbscontDistribution"'.
      Class '"Distribution"', by class '"AbscontDistribution"'.

_M_e_t_h_o_d_s:

     _i_n_i_t_i_a_l_i_z_e 'signature(.Object = "Unif")': initialize method 

     _M_i_n 'signature(object = "Unif")': returns the slot 'Min' of the
          parameter of the distribution 

     _M_i_n<- 'signature(object = "Unif")': modifies the slot 'Min' of the
          parameter of the distribution 

     _M_a_x 'signature(object = "Unif")': returns the slot 'Max' of the
          parameter of the distribution 

     _M_a_x<- 'signature(object = "Unif")': modifies the slot 'Max' of the
          parameter of the distribution 

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

     Thomas Stabla Thomas.Stabla@uni-bayreuth.de,
      Florian Camphausen Florian.Camphausen@uni-bayreuth.de,
      Peter Ruckdeschel Peter.Ruckdeschel@uni-bayreuth.de,
      Matthias Kohl Matthias.Kohl@uni-bayreuth.de

_S_e_e _A_l_s_o:

     'UnifParameter-class' 'AbscontDistribution-class' 'Reals-class'
     'runif'

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

     U=Unif(Min=0,Max=2) # U is a uniform distribution with Min=0 and Max=2.
     r(U)(1) # one random number generated from this distribution, e.g. 1.984357
     d(U)(1) # Density of this distribution is 0.5 for x=1.
     p(U)(1) # Probability that x<1 is 0.5.
     q(U)(.1) # Probability that x<0.2 is 0.1.
     Min(U) # Min of this distribution is 0.
     Min(U)=1 # Min of this distribution is now 1.

