getMappedRT {DIAlignR} | R Documentation

## Get mapping of reference RT on experiment run.

### Description

This function aligns XICs of reference and experiment runs. Using alignment, it maps retention time from refernce run on experiment run.

### Usage

    getMappedRT(refRT, XICs.ref, XICs.eXp, Loess.fit, alignType, adaptiveRT,
      samplingTime, normalization, simMeasure, goFactor, geFactor,
      cosAngleThresh, OverlapAlignment, dotProdThresh, gapQuantile,
      hardConstrain, samples4gradient, objType = "light")

### Arguments

`refRT` | Peak's retention-time in reference run.
`XICs.ref` | List of extracted ion chromatograms from reference run.
`XICs.eXp` | List of extracted ion chromatograms from experiment run.
`Loess.fit` | LOESS fit object between reference and experiment run.
`alignType` | Available alignment methods are "global", "local" and "hybrid".
`adaptiveRT` | (numeric) Similarity matrix is not penalized within adaptive RT.
`samplingTime` | (numeric) Time difference between two data-points in each chromatogram. For hybrid and local alignment, samples are assumed to be equally time-spaced.
`normalization` | (character) Must be selected from "mean", "l2".
`simMeasure` | (string) Must be selected from dotProduct, cosineAngle, cosine2Angle, dotProductMasked, euclideanDist, covariance and correlation.
`goFactor` | (numeric) Penalty for introducing first gap in alignment. This value is multiplied by base gap-penalty.
`geFactor` | (numeric) Penalty for introducing subsequent gaps in alignment. This value is multiplied by base gap-penalty.
`cosAngleThresh` | (numeric) In simType = dotProductMasked mode, angular similarity should be higher than cosAngleThresh otherwise similarity is forced to zero.
`OverlapAlignment` | (logical) An input for alignment with free end-gaps. False: Global alignment, True: overlap alignment.
`dotProdThresh` | (numeric) In simType = dotProductMasked mode, values in similarity matrix higher than dotProdThresh quantile are checked for angular similarity.
`gapQuantile` | (numeric) Must be between 0 and 1. This is used to calculate base gap-penalty from similarity distribution.
`hardConstrain` | (logical) If FALSE; indices farther from noBeef distance are filled with distance from linear fit line.
`samples4gradient` | (numeric) This parameter modulates penalization of masked indices.
`objType` | (char) Must be selected from light, medium and heavy.

### Value

(numeric)

### Author(s)

Shubham Gupta, shubh.gupta@mail.utoronto.ca

ORCID: 0000-0003-3500-8152

License: (c) Author (2019) + GPL-3 Date: 2019-12-13

### See Also

`alignChromatogramsCpp`

### Examples

    data(XIC_QFNNTDIVLLEDFQK_3_DIAlignR, package="DIAlignR")
    data(oswFiles_DIAlignR, package="DIAlignR")
    XICs.ref <- XIC_QFNNTDIVLLEDFQK_3_DIAlignR[["run1"]][["14299_QFNNTDIVLLEDFQK/3"]]
    XICs.eXp <- XIC_QFNNTDIVLLEDFQK_3_DIAlignR[["run2"]][["14299_QFNNTDIVLLEDFQK/3"]]
    Loess.fit <- getGlobalAlignment(oswFiles_DIAlignR, ref = "run2", eXp = "run0",
     maxFdrGlobal = 0.05, spanvalue = 0.1)
    adaptiveRT <- 77.82315 #3.5*Loess.fit$s
    getMappedRT(refRT = 5238.35, XICs.ref, XICs.eXp, Loess.fit, alignType = "hybrid",
     adaptiveRT = adaptiveRT, samplingTime = 3.414, normalization = "mean",
      simMeasure = "dotProductMasked", goFactor = 0.125, geFactor = 40, cosAngleThresh = 0.3,
      OverlapAlignment = TRUE, dotProdThresh = 0.96, gapQuantile = 0.5, hardConstrain = FALSE,
      samples4gradient = 100)

[Package DIAlignR version 0.99.12 Index]