addPrimingWeights {Genominator} | R Documentation |
This function adds priming weights to an AlignedRead object.
addPrimingWeights(aln, weights = NULL, overwrite = FALSE, ...)
aln |
An object of class |
weights |
A vector of weights as produced by |
overwrite |
A logical, will a |
... |
These arguments are passed to |
If the weights are not supplied, the weights are calculated using the
aln
object itself.
An object of class AlignedRead
with a weights
component
in its alignData
slot.
Kasper Daniel Hansen khansen@jhsph.edu.
Hansen, K. D., Brenner, S. E. and Dudoit, S (2010) Biases in Illumina transcriptome sequencing caused by random hexamer priming. Nucleic Acids Res, doi:10.1093/nar/gkq224
computePrimingWeights
and the extended example in the
'Working with ShortRead' vignette.
if(require(ShortRead)) { bwt.file <- system.file("extdata", "bowtie", "s_1_aligned_bowtie.txt", package="ShortRead") aln <- readAligned(bwt.file, type = "Bowtie") weights <- computePrimingWeights(aln, weightsLength = 2L) aln <- addPrimingWeights(aln, weights = weights) head(alignData(aln)$weights) }