Description Usage Arguments Value Examples
The function allows you to briefly know how many peaks you have in a waveform
1 |
y |
is the waveform intensities. |
drop |
is the index of waveform index we should ingore or non-intensity of waveform information.Default is c(0,0) that means use the all input data. |
smooth |
is tell whether you want to smooth the waveform to reduce the effect of some obvious noise. Default is TRUE. |
threshold |
is to determine if the detected peak is the real peak whose intensity should be higher than threshold*maximum intensity. Default is 0.2. |
return the number of waveform componments.
1 2 3 4 5 6 7 8 9 10 11 | ##import return waveform data
data(return)
###individual waveform
x<-return[1,]
npeaks(x)
npeaks(x,smooth=FALSE) ##it will use the raw data to detect peaks
#you can set up threshold to determine if peaks are correctly identified.
npeaks(x,smooth=FALSE,threshold=0.25)
###if there are some columns are not intensity, you can delete before you process
y<-c(c(1,2,3),as.numeric(x))
npeaks(y,drop=c(1,3))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.