getPCRanks: Get CpG eigenvector scores from a principle component.

View source: R/getPCRanks.R

getPCRanksR Documentation

Get CpG eigenvector scores from a principle component.

Description

Returns eigenvector scores for input CpG sites.

Usage

getPCRanks(mat, IDs, PC, filter_thresh)

Arguments

mat

Bismark2Matrix.R output file, or data frame object

IDs

A character vector of IDs containing the common names for compared conditions. E.g., for samples trt1 & trt2 vs. ctl1 & ctl2, IDs=c("trt1", "ctl")

PC

Integer, which principle component to use. Use to DefineBestPC if unsure.

filter_thresh

Integer, a coverage threshold for filtering, where CpG coverage of all samples must be larger than this value.

Value

Returns a data.frame of eigenvector scores for all loci.

Examples

ranks <- getPCRanks(eigen, IDs = c("trt", "ctl"), PC = 1)

PCBS documentation built on Sept. 11, 2024, 6:11 p.m.

Related to getPCRanks in PCBS...