BMfinder: Discover bimodal distrubition features

Description Usage Arguments Details Value Examples

View source: R/BMfinder.R

Description

Find bimodal distrubition features and divide the samples into 2 groups by k-means clustering.

Usage

1
2
3
4
5
6
7
8
9
BMfinder(
  x,
  p.value = 0.01,
  maf = 0.05,
  miss = 0.05,
  fold = 2,
  log = FALSE,
  cores = detectCores() - 1
)

Arguments

x

a numeric matrix with feature rows and sample columns, e.g., splicing score matrix from spliceGenome or spliceGene function.

p.value

p.value threshold for bimodal distrubition test

maf

minor allele frequency threshold in k-means clustering

miss

missing grouping rate threshold in k-means clustering

fold

fold change threshold between the two groups

log

whether the scores are to be logarithmic. If TRUE, all the scores are log2 tranformed before k-means clustering: x = log2(x+1).

cores

threads to be used. This value is passed to mclapply in parallel package

Details

The matrix contains 1, 2 and NA, and values of 'x' in group 2 are larger than group 1.

Value

a matrix with feature rows and sample columns.

Examples

1
2
3
4
5
6
7
8
data(rice.bg)
score <- spliceGene(rice.bg, "MSTRG.183", junc.type = "score")
score <- round(score, 2)
as <- BMfinder(score, cores = 1)  # 4 bimodal distrubition features found

## compare
as
score[rownames(score) %in% rownames(as), ]

yuhuihui2011/vasp_test documentation built on March 5, 2020, 12:50 a.m.