Description Usage Arguments Details Value Note Author(s) See Also Examples
Fits a seqbias module given a reference sequence and reads in BAM format
1 | seqbias.fit(ref_fn, reads_fn, n = 1e5, L = 15, R = 15)
|
ref_fn |
filename of a reference sequence against which the reads are aligned, in FASTA format. |
reads_fn |
filename of aligned reads in BAM format. |
n |
train on at most this many reads. |
L |
consider at most L positions to the left of the read start. |
R |
consider at most R positions to the right of the read start. |
A Bayesian network is trained on the first n
unique reads in the provided
BAM file, predicting the posterior probability of a read beginning at a
position given the surrounding sequence. This is used to discern the
sequencing bias: how more or less likely a read is to fall on a particular
position.
The abundance of region can be more accurately assessed by normalizing (dividing) each position by its predicted bias.
A vector of reals giving the predicted sequencing bias for each position.
Both the BAM file and the FASTA file should be indexed, with, 'samtools index' and, 'samtools faidx' respectively.
Daniel Jones dcjones@cs.washington.edu
1 2 3 4 5 6 7 8 | reads_fn <- system.file( "extra/example.bam", package = "seqbias" )
ref_fn <- system.file( "extra/example.fa", package = "seqbias" )
sb <- seqbias.fit( ref_fn, reads_fn )
I <- GRanges( c('seq1'), IRanges( c(1), c(5000) ), strand = c('-') )
bias <- seqbias.predict( sb, I )
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.