covarAssociationCheck: Calculate association between components and given covariates

Description Usage Arguments Value Examples

View source: R/covariateAssociationCheck.R

Description

Check the association between sample covariates and independent/principal components.

Usage

1
2
covarAssociationCheck(input_list = NULL, covars = NULL, col_names = NULL,
  cor_threshold = 0.05)

Arguments

input_list

ICA or PCA object generated by runICA() or runPCA().

covars

A dataframe of covariates with each row for a sample and each column for a covariate.

col_names

Column names of covars to be used for association testing. Default is to test every input covariate.

cor_threshold

Bonferroni threshold that is going to be used for identifying significant associations.

Value

The output will be the input_list with additional entries comp_cov, covars, covar_threshold, covar_pvals. comp_cov will contain a list with entries for each component showing the associated covariate and p-value. covars will contain a copy of sample_info to keep all the data in one place. covar_threshold will record the threshold used to call significant associations. covar_pvals will contain the matrix of p-values for all covariate and component pairs.

Examples

1
2
3
4
5
data(expr_data, sample_info)

pca_result <- runPCA(expr_data)

pca_result <- covarAssociationCheck(pca_result, covars = sample_info)

jinhyunju/picaplot documentation built on May 19, 2019, 10:35 a.m.