Convert signatures between mutational opportunity representations
Source:R/ms-convert.R
ms_convert.RdRe-expresses SBS96 signatures relative to a different mutation opportunity vector (whole-genome vs whole-exome trinucleotide frequencies, or a custom vector): divide by the source opportunities, multiply by the target ones, re-normalize each column (the sigfit `convert_signatures` semantics). The bundled tables come from the COSMIC v2/v3 signature database (via sigfit/sigminer); custom opportunity vectors are accepted for panel targets.
Arguments
- signatures
A 96 x k numeric matrix with SBS96 registry rownames (columns sum to 1 after conversion), or an [MsSignature].
- from
Source opportunity: `"human-genome"`, `"human-exome"`, or a numeric vector of 96 positive finite frequencies (named by the registry labels, or matching the signature rownames).
- to
Target opportunity: same forms as `from`.