dbtopower                package:emu                R Documentation

_F_u_n_c_t_i_o_n _f_o_r _i_n_t_e_r-_c_o_n_v_e_r_t_i_n_g _b_e_t_w_e_e_n _d_e_c_i_b_e_l_s _a_n_d _a _l_i_n_e_a_r _s_c_a_l_e

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

     The function converts from decibels to a linear scale

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

     dbtopower(specdata, const = 10, base = 10, inv = FALSE)

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

specdata: A numeric object or an object of class trackdata 

   const: A single element numeric vector. Defaults to 10 

    base: A single element numeric vector. Defaults to 10 

     inv: Logical. If T, then the conversion is from a logarithmic to
          an anti-logarithmic form, otherwise the other way round 

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

     The function returns base^(specdata/const) if  inv=F, otherwise, 
     const * log(dat, base=base). If the object to which this function
     is applied is of class 'trackdata' then this function is applied
     to $data.

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

     An object of the same class.

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

     Jonathan Harrington

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

     'dbtopower' 'plot.spectral'

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

     # convert 10 dB to a power ratio
     vec = dbtopower(10)
     # convert dB-data to a power ratio and back to decibels
     res = dbtopower(vowlax.dft.5)
     res = dbtopower(res, inv=TRUE)

