frac                 package:cwhmath                 R Documentation

_F_r_a_c_t_i_o_n_a_l _p_a_r_t _o_f _n_u_m_b_e_r

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

     Split off fractional part of a number

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

       frac(x,d)

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

       x: Numerical vector.

       d: If not missing, determines number of decimals after "."

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

     fractional part, if 'd' is missing; else round(10^d*fractional
     part), i.e. the digits without the leading "0.".

_N_o_t_e:

     'd' not missing is practical for use in 'dc'

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

     Christian W. Hoffmann, christian.hoffmann@wsl.ch, 
      <URL: http://www.wsl.ch/staff/christian.hoffmann>

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

     frac(c(0,pi,2*pi,30*pi))    # 0.000000 0.141593 0.283185 0.247780
     frac(c(0,pi,2*pi,30*pi),3)  # 0 142 283 248

