Contribution-class {plasma}R Documentation

Class "Contribution"

Description

The Contribution object class contains the weight matrix between variables and the PLS components. The values in the weight matrix are a numeric representation of how much a variable from the omics datasets contributed to defining the final PLS components.

Usage

getCompositeWeights(object, N, M)
getAllWeights(object, N)
getFinalWeights(object)
getTop(object, N = 1)
pickSignificant(object, alpha)
## S4 method for signature 'Contribution'
summary(object, ...)
## S4 method for signature 'Contribution'
image(x, col = viridis(64), mai = c(1.82, 1.52, 0.32, 0.32), ...)
## S4 method for signature 'Contribution'
heat(object, main = "Contributions", col = viridis(64),
                                           mai = c(1.52, 0.32, 0.82, 1.82), ...)

Arguments

object

In the first four functions, an object of the plasma class. In the methods described here, an object of the Contributions class.

N

in the function getCompositeWeights, the name of the dataset being modeled.
in the function getTop, the number of significant components you want to print.

M

name of the dataset being modeled pairwise with dataset N in the getCompositeWeights function.

alpha

level of significance used in the pickSignificant function.

...

other graphical parameters.

x

an object of the Contributions class.

main

A character vector of length one; the main plot title.

col

A vector of color descriptors.

mai

A vector of four nonnegative numbers.

Value

The plasma function returns a newly constructed object of the plasma class.

Objects from the Class

Objects are defined using the getAllWeights, getCompositeWeights, getTop, or pickSignificant functions. In the simplest scenario, one would enter an object of class plasma and any specific parameters associated with the function (see arguments section for more info).

Slots

contrib:

a matrix of the original variables in dataset N as rows and the PLS components M as columns.

datasets:

a character vector that stores the names of the datasets that were specified for the function.

Methods

summary:

outputs summary statistics for the contributions of dataset N to components from all datasets in the case of getAllWeights or dataset M in the case of getCompositeWeights.

image:

outputs a heatmap of the transposed contrib matrix.

heat:

outputs a clustered heatmap of the contrib matrix.

Author(s)

Kevin R. Coombes krc@silicovore.com, Kyoko Yamaguchi kyoko.yamaguchi@osumc.edu

Examples

fls <- try(loadESCAdata())
if (inherits(fls, "try-error")) {
  stop("Unable to load data from remote server.")
}
# restrict data set size
MO <- with(plasmaEnv, prepareMultiOmics(
    assemble[c("ClinicalBin", "ClinicalCont", "RPPA")], Outcome))

splitVec <- with(plasmaEnv, rbinom(nrow(Outcome), 1, 0.6))
trainD <- MO[, splitVec == 1]
testD <- MO[, splitVec == 0]

firstPass <- fitCoxModels(trainD, "Days", "vital_status", "dead")
pl <- plasma(object = trainD, multi = firstPass)

getCompositeWeights(object = pl, N = "ClinicalBin", M = "RPPA")

cbin <- getAllWeights(object = pl, N = "ClinicalBin")
summary(cbin)
image(cbin)
heat(cbin, cexCol = 0.5)

cbin01 <- pickSignificant(object = cbin, alpha = 0.01)
image(cbin01)
heat(cbin01, cexCol = 0.5)

getTop(object = cbin01, N = 3)

[Package plasma version 1.1.3 Index]