sampleSpecialization: Entropy-based sample specialization

Description Usage Arguments Value References See Also Examples

View source: R/entropy.R

Description

Entropy-based sample specialization

Usage

1

Arguments

mat

A matrix (usually an expression matrix), with genes (features) in rows and samples in columns.

norm

Logical, whether the specialization should be normalized by log2(ncol(mat)).

Value

A vector as long as the column number of the input matrix

References

Martinez and Reyes-Valdes (2008) Defining diversity, specialization, and gene specificity in transcriptomes through information theory. PNAS 105(28):9709–9714

See Also

entropy and entropyDiversity

Examples

1
2
3
4
5
6
7
myMat <- rbind(c(3,4,5),c(6,6,6), c(0,2,4))
sampleSpecialization(myMat)
sampleSpecialization(myMat, norm=TRUE)

myRandomMat <- matrix(runif(1000), ncol=20)
sampleSpecialization(myRandomMat)
sampleSpecialization(myRandomMat, norm=TRUE)

Example output

Loading required package: Biobase
Loading required package: BiocGenerics
Loading required package: parallel

Attaching package:BiocGenericsThe following objects are masked frompackage:parallel:

    clusterApply, clusterApplyLB, clusterCall, clusterEvalQ,
    clusterExport, clusterMap, parApply, parCapply, parLapply,
    parLapplyLB, parRapply, parSapply, parSapplyLB

The following objects are masked frompackage:stats:

    IQR, mad, sd, var, xtabs

The following objects are masked frompackage:base:

    anyDuplicated, append, as.data.frame, basename, cbind, colnames,
    dirname, do.call, duplicated, eval, evalq, Filter, Find, get, grep,
    grepl, intersect, is.unsorted, lapply, Map, mapply, match, mget,
    order, paste, pmax, pmax.int, pmin, pmin.int, Position, rank,
    rbind, Reduce, rownames, sapply, setdiff, sort, table, tapply,
    union, unique, unsplit, which.max, which.min

Welcome to Bioconductor

    Vignettes contain introductory material; view with
    'browseVignettes()'. To cite Bioconductor, see
    'citation("Biobase")', and for packages 'citation("pkgname")'.

[1] 0.01332588 0.07558228 0.11293612
[1] 0.01332588 0.07558228 0.11293612
 [1] 0.06226725 0.05979973 0.06259196 0.05994737 0.05941794 0.06363914
 [7] 0.06320528 0.06105567 0.06554557 0.06252926 0.06109413 0.06215663
[13] 0.06440363 0.06244250 0.06356424 0.06040522 0.06224945 0.06280054
[19] 0.06173870 0.06038039
 [1] 0.06226725 0.05979973 0.06259196 0.05994737 0.05941794 0.06363914
 [7] 0.06320528 0.06105567 0.06554557 0.06252926 0.06109413 0.06215663
[13] 0.06440363 0.06244250 0.06356424 0.06040522 0.06224945 0.06280054
[19] 0.06173870 0.06038039

BioQC documentation built on Nov. 8, 2020, 7:16 p.m.