| ValidateSATSInputs | R Documentation |
Validate and align SATS mutation-count, panel-context, signature-profile and signature-activity matrices before running refitting or burden calculation.
ValidateSATSInputs(V=NULL, L=NULL, W=NULL, H=NULL)
V |
Optional mutation-count matrix or data frame with mutation contexts in rows and samples in columns. Values must be non-negative, finite and integer-like. |
L |
Optional panel-context matrix or data frame with mutation contexts in rows and samples in columns. Values must be non-negative and finite. |
W |
Optional catalog signature-profile matrix or data frame with mutation contexts in rows and signatures in columns. Values must be non-negative and finite. |
H |
Optional signature-activity matrix or data frame with signatures in rows and samples in columns. Values must be non-negative and finite. |
ValidateSATSInputs() performs the same matrix-level checks used
internally by EstimateSigActivity and
CalculateSignatureBurdens. It checks object type, matrix
dimensions, numeric values, finite values, non-negative values, duplicated or
missing row and column identifiers, mutation-context alignment, sample-ID
alignment and signature-name alignment.
When compatible names are present in a different order, the returned matrices
are reordered to a common order. For example, L and W are
reordered to match V for activity estimation, and L and W
are reordered to match H for burden calculation. If one object has names
on an axis used for alignment and the paired object does not, or if the named
entries differ, the function stops with an informative error. If paired axes
are both unnamed, validation proceeds by dimension.
A named list containing the supplied matrices after compatible named axes have been aligned. Objects that were not supplied are omitted from the returned list.
Donghyuk Lee <dhyuklee@pusan.ac.kr> and Bin Zhu <bin.zhu@nih.gov>
EstimateSigActivity,
CalculateSignatureBurdens
data(SimData, package="SATS")
obj <- ValidateSATSInputs(
V = SimData$V[, 1:3],
L = SimData$L[, c(3, 1, 2)],
W = SimData$TrueW_TMB
)
identical(colnames(obj$L), colnames(obj$V))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.