Learn R Programming

crlmm (version 1.30.0)

posteriorProbability: Calculate the posterior probability for integer copy numbers.

Description

Calculate the posterior probability for integer copy numbers using the bivariate normal prediction regions.

Usage

posteriorProbability(object, predictRegion, copyNumber = 0:4, w)

Arguments

object
A CNSet object.
predictRegion
A list containing the bivariate normal prediction region for each of the possible genotypes.
copyNumber
Integer vector.
w
numeric vector of prior probabilities for each of the copy number states. Must be the same length as copyNumber and sum to 1.

Value

An array (features x samples x copy number)

Details

This is currently under development.

See Also

predictionRegion, genotypes

Examples

Run this code
data(cnSetExample)
pr <- predictionRegion(cnSetExample, copyNumber=0:4)
pp <- posteriorProbability(cnSetExample, predictRegion=pr)
dim(pp)

## multiple batches
data(cnSetExample2)
pr <- predictionRegion(cnSetExample2, copyNumber=0:4)
pp <- posteriorProbability(cnSetExample2, predictRegion=pr)

Run the code above in your browser using DataLab