netInformation: Calculate net total information explained

Description Usage Arguments Value Examples

View source: R/Het.R

Description

Calculates total macro-heterogeneity regularised by the entropy of the group structure

Usage

1
netInformation(CountsMatrix, Groups, Het, lambda, base = 2)

Arguments

CountsMatrix

Feature x cell sparse counts matrix of class dgCMatrix

Groups

Factor of cell identities

Het

Vector of feature Het values

lambda

Scale factor of regularisation; defaults to ratio of total information obtained to theoretical maximum

base

base of log

Value

Net total information explained

Examples

1
2
3
4
5
Counts <- Matrix::sparseMatrix(i = c(1,1,1,1,2,2,2),
                               j = c(1,2,3,4,1,2,3),
                               x = c(2,2,2,2,3,3,2))
Ident <- factor(c("1", "1", "2", "2"))
netInformation(Counts, Ident)

mjcasy/infohet documentation built on May 4, 2021, 1:09 a.m.