Metabolomics processing, standards and feature interpretation

Practical 17: Genomics, systems biology and multi-omics

Learning objectives

Evaluate a multiplicative-drift correction; preserve feature identity and measurement units; distinguish detected features from assigned metabolites.

Biological question and data

How does an internal standard help distinguish instrument drift from a supplied concentration pattern?

The first calculation has an ideal shared drift factor affecting analyte and standard equally. The fixture metabolite table is already log2 arbitrary abundance; its feature labels do not identify actual compounds.

No biological download is required. Numerical inputs are hypothetical, not observed animal data. The runnable examples use base R. Count and abundance units are specified where used.

1. Test an ideal measurement correction

An analyte and a standard are multiplied by the same hypothetical response factor.

Show R code
concentration <- c(2,3,5,4,3,6)
drift <- c(.8,.9,1,1.1,1.2,1.3)
raw <- concentration*drift
standard <- 10*drift
corrected <- 10*raw/standard
data.frame(concentration,raw,standard,corrected)
  concentration raw standard corrected
1             2 1.6        8         2
2             3 2.7        9         3
3             5 5.0       10         5
4             4 4.4       11         4
5             3 3.6       12         3
6             6 7.8       13         6
Show R code
stopifnot(max(abs(corrected-concentration))<1e-12)

Correction is exact only because the generating process supplies a shared multiplier and a stable standard.

2. Break the standard assumption

Allow analyte response to vary differently from the standard.

Show R code
analyte_drift <- drift*c(1,.95,1.1,.9,1.05,1)
biased <- 10*(concentration*analyte_drift)/standard
data.frame(concentration,estimate=biased,error=biased-concentration)
  concentration estimate error
1             2     2.00  0.00
2             3     2.85 -0.15
3             5     5.50  0.50
4             4     3.60 -0.40
5             3     3.15  0.15
6             6     6.00  0.00

A standard cannot correct variation it does not track. Chemical properties and preparation can give different responses.

3. Explore a separate log2 feature panel

Maintain labels and scales before plotting. The annotation-confidence labels are fictional examples.

Show R code
helper_dir <- if (dir.exists("R")) "R" else "../R"
stopifnot(file.exists(file.path(helper_dir,"teaching_data.R")))
source(file.path(helper_dir,"teaching_data.R"))
d <- teaching_data()
M <- d$metabolite
identity <- data.frame(feature=rownames(M),assignment=c("hypothetical named candidate","unresolved feature",
 "unresolved feature","hypothetical named candidate","unresolved feature","unresolved feature"))
identity
    feature                   assignment
1 feature01 hypothetical named candidate
2 feature02           unresolved feature
3 feature03           unresolved feature
4 feature04 hypothetical named candidate
5 feature05           unresolved feature
6 feature06           unresolved feature
Show R code
boxplot(M[1,]~d$metadata$diet,xlab="Diet",ylab="Supplied log2 abundance",col="#86B7A3")

Show R code
c(log2_mean_difference=mean(M[1,d$metadata$diet=="supplement"])-
 mean(M[1,d$metadata$diet=="control"]))
log2_mean_difference 
           0.3455385 

The difference describes the hypothetical panel. A mass-spectrometry feature cannot be assigned to a pathway merely because its group contrast is large.

4. Inspect a calibration range

A hypothetical linear standard curve can convert a signal to concentration only under its assumptions. Show whether an unknown lies inside the supplied range.

Show R code
standard_curve <- data.frame(C=c(0,1,2,4),signal=c(2,12,22,42))
fit_cal <- lm(signal~C,standard_curve)
unknown <- c(17,62)
conc <- (unknown-coef(fit_cal)[1])/coef(fit_cal)[2]
data.frame(signal=unknown,estimated_C=conc,in_range=conc>=0 & conc<=4)
  signal estimated_C in_range
1     17         1.5     TRUE
2     62         6.0    FALSE

5. Connect quantification and identity

A correct drift ratio does not identify the compound. Conversely, a confirmed identity does not make an arbitrary signal an absolute concentration. Keep calibration, internal-standard assumptions and identification confidence as separate fields.

Use blanks to investigate background and pooled QC to investigate acquisition drift. These controls address technical variation, while independent animals address biological variation. If acquisition order follows treatment, correction can be difficult to distinguish from removing the biological comparison.

Interpretation challenge

An estimate outside the highest standard looks numerically precise. Is it a validated concentration?

No. It is an extrapolation under the fitted model. Assess the assay range, matrix effects, uncertainty and additional standards before treating it as validated quantification.

Interpretation and limits

Real workflows need blanks, technical QC, drift and batch assessment, detection/identification confidence and justified normalization. The EMBL-EBI metabolite-identification material explains why chemical assignment is separate from signal detection.

Exercises

  1. Why did the imperfect correction fail?
  2. Would another log transform be appropriate for M?
  3. Can an unresolved feature support a named pathway claim?
  1. The standard did not share the same response factor as the analyte.
  2. No; M already represents log2 abundance.
  3. Not without justified chemical identification or carefully qualified evidence.

Continue learning

B09 Metabolomics and B12 Statistics.

Continue with exploration or integration. Return to the practical index or the unified map.