Learn R Programming

AllelicImbalance (version 1.10.2)

randomRef: Random ref allele from genotype

Description

Create a vector of random reference alleles

Usage

randomRef(x, ...)
"randomRef"(x, source = "alleleCounts", ...)

Arguments

x
ASEset object
...
internal arguments
source
'alleleCounts'

Details

Randomly shuffles which of the two alleles for each genotype that is indicated as reference allele, based on either allele count information or previous ref and alt alleles.

When the source is 'alleleCounts', the two most expressed alleles are taken as reference and alternative allele.

Examples

Run this code

#load example data
data(ASEset.sim)
a <- ASEset.sim

ref(a) <- randomRef(a, source = 'alleleCounts') 

Run the code above in your browser using DataLab