Adaptive Inteligent Binning (aibin) recursively finds bin edges in existing bins by maximizing the information contained in each newly created bin.
bucket_aibin(x, ...) # S3 method for collection bucket_aibin(x, R, noise_region, snr = 1, skip = FALSE, ...)
x | A |
---|---|
... | further arguments passed to or from other methods(not currenctly used). |
R | resolution value, strictly positive and typically in the interval 0 > R >= 1. |
noise_region | A |
snr | Signal to noise ratio for bucketting. snr should a real >=1. Factor by which to multiply the noise bin value. Can be useful to limit overbucketing of high-resolution data or in case of very smooth and low noise. |
skip | Skip the creation of of processor step. If TRUE, this step will not be added to the list of processing steps. Typically reserved for nested function calls. |
An updated version of x
AI binning will first consider the entire spectra as a single bin. It will then consider every position in the spectra as a potential splitting candidate and calulate a quality value for each splitting candidate. If the best splitting candidates fulfills quality requirements, the bin will be split and the process will be repeated on the newly created bins.
In order to limit splitting in local minima of noisy regions a minimal quality value is computed from the user-provided noise-region.
The amount of created bins is not directly depending of a high or low R. If a maximal splitting is looked for, you should try several different values in the possible rangeof R (see references). However the differences in binning should limited to bins that are borderline noise and most likely has limited effect in the downstream analysis.
De Meyer T, Sinnaeve D, Van Gasse B, Tsiporkova E, Rietzschel ER, De Buyzere ML, Gillebert TC, Bekaert S, Martins JC, Van Criekinge W. NMR-based characterization of metabolic alterations in hypertension using an adaptive, intelligent binning algorithm. Anal Chem. 2008 May 15;80(10):3783-90. doi: 10.1021/ac7025964. https://pubmed.ncbi.nlm.nih.gov/18419139/
library(tidySpectR) # First we normalize the dataset and extract noise and sepctra regions normalized <- fa_nmr %>% normalize_internalStandard(3.58, 3.64) spectra <- normalized %>% extract(0.5, 7.2) noise <- normalized %>% extract(7.5, Inf) bucketted <- bucket_aibin(spectra, 0.5, noise) bucketted#> Spectra collection containing 6 entries. #> Number of bins: 164 #> Limits: 0.4999788 7.203979 #> Labels: conventional organic #> #> Processing: #> Step 1 / 3 : internalStandard_normalization #> Step 2 / 3 : extract #> Step 3 / 3 : aibin