prepareTbl: Helper function to create the output of createLoadingsTbl

Description Usage Arguments Details Examples

View source: R/quantifyViaLoadings.R

Description

The function prepareTbl prepares the input for createLoadingsTbl using the intensity values (values) and the tibble with markers (markers).

Usage

1
prepareTbl(values, markers, PC = "PC1")

Arguments

values

matrix or data.frame

markers

tbl

PC

character, has to be in the format "PC1", "PC2", "PC3", ..., the specification of multiple principal components is possible and the length of loadings vectors will be calculated using these principal components

Details

The function will call internally the helper function combineLoadings. This means the function will return absolute loadings values even in the case of only one selected principal component.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
library(MatrixQCvis)
library(SummarizedExperiment)

## load data set of Tanzer et al. (2020)
## source: https://www.ebi.ac.uk/pride/archive/projects/PXD014966
f <- system.file("protein_datasets/tanzer2020.RDS", 
    package = "apoptosisQuantification")
tanzer2020 <- readRDS(f)

## get loadings of markers and of the complete data set
prot <- assay(tanzer2020)
markers <- readMarkers(type = "apoptosis")

apoptosisQuantification:::prepareTbl(values = prot, markers = markers, 
    PC = "PC1")

tnaake/apoptosisQuantification documentation built on Feb. 20, 2022, 5:37 p.m.