tuneInPeakInfo        package:MassSpecWavelet        R Documentation

_T_u_n_e _i_n _t_h_e _p_e_a_k _i_n_f_o_r_m_a_t_i_o_n: _p_e_a_k _p_o_s_i_t_i_o_n _a_n_d _p_e_a_k _s_c_a_l_e

_D_e_s_c_r_i_p_t_i_o_n:

     Based on the identified peak position, more precise estimation of
     the peak information, i.e., peak position and peak scale, can be
     got by this function. The basic idea is to cut the segment of
     spectrum near the identified peaks, and then do similar procedures
     as 'peakDetectionCWT', but with more detailed scales around the
     estimated peak scale.

_U_s_a_g_e:

     tuneInPeakInfo(ms, majorPeakInfo = NULL, peakIndex = NULL, peakScale = NULL, maxScale = 128, ...)

_A_r_g_u_m_e_n_t_s:

      ms: the mass spectrometry spectrum 

majorPeakInfo: return of 'identifyMajorPeaks' 

peakIndex: the m/z index of the identified peaks

peakScale: the scales of the identified peaks 

maxScale: the maximum scale allowed for the peak 

     ...: other parameters of used by 'getLocalMaximumCWT', 'getRidge',
          'identifyMajorPeaks' 

_D_e_t_a_i_l_s:

     The majorPeakInfo or peakIndex and peakScale must be provided.

_V_a_l_u_e:

peakCenterIndex: the updated peak center m/z index

peakScale: the updated peak scale

peakValue: the corresponding peak value

_A_u_t_h_o_r(_s):

     Pan Du

_R_e_f_e_r_e_n_c_e_s:

     Du, P., Kibbe, W.A. and Lin, S.M. (2006) Improved peak detection
     in mass spectrum by incorporating continuous wavelet
     transform-based pattern matching, Bioinformatics, 22, 2059-2065.

_S_e_e _A_l_s_o:

     'peakDetectionCWT'

_E_x_a_m_p_l_e_s:

             data(exampleMS)
             SNR.Th <- 3
             peakInfo <- peakDetectionCWT(exampleMS, SNR.Th=SNR.Th)
             majorPeakInfo <- peakInfo$majorPeakInfo
             betterPeakInfo <- tuneInPeakInfo(exampleMS, majorPeakInfo)
             plot(500:length(exampleMS), exampleMS[500:length(exampleMS)], type='l', log='x')
             abline(v=betterPeakInfo$peakCenterIndex, col='red')

