shift_pickr() is programmed to search a given ppm region for a maximum value (i.e., the apex of a metabolite peak) and return the chemical shift that best encapsulates said peak. Is most useful when picking peaks to estimate their area.

shift_pickr(x, p, sh, pm = 0.005)

Arguments

x

The spectrum of which you want to calculate the total area

p

The matched ppm variable to x

sh

Takes arrangements of values:

  1. The first is two values where the first is the lower ppm value and the second is the upper ppm value. This is then parsed to get_idx() to find the idx which is then parsed to the x variable.

  2. The second arrangement is an array of numbers that are interpreted as the already calculated idx values and are parse straight to the x variable

pm

The plus/minus value you want to add or subtract from the peak. Default = 0.005

Value

An array of values mapped to defined peak

Details

shift_pickr() takes chemical shift region in the sh parameter and searches for the largest value in x in that chemical shift. From there, the value of pm is added and subtracted from the ppm where the maximum x values resides to give a shift that best encapsulates the peak which is then returned by the function.

See also

Other estimation: alter8r(), citra(), crea(), get_idx(), noi_(), roundr(), tota()

Author

Kyle Bario kylebario1@gmail.com

Examples

data(x,p) idx <- shift_pickr(x, p, sh = c(5,5.5), pm = 0.01)