Description Usage Arguments Details Value Author(s) Examples
View source: R/qualityScores.R
Extract quality strings and convert them to Phred scores for generating boxplots.
1 2 3 4 5 6 7 | qualityScores(
# basic input/output options
filename,
input_format = "gzFASTQ",
offset = 33,
nreads = 10000)
|
filename |
a character string giving the name of an input file containing sequence reads. |
input_format |
a character string specifying format of the input file. |
offset |
a numeric value giving the offset added to the base-calling Phred scores. Possible values include |
nreads |
a numeric value giving the number of reads from which quality scores are extracted. |
Quality scores of read bases are represented by ASCII characters in next-gen sequencing data.
This function extracts the quality characters from each base in each read and then converts them to Phred scores using the provided offset value (offset
).
If the total number of reads in a dataset is n
, then every n
/nreads
read is extracted from the input data.
A data matrix containing Phred scores for read bases. Rows in the matrix are reads and columns are base positions in each read.
Wei Shi, Yang Liao and Zhiyin Dai
1 2 3 | reads <- system.file("extdata","reads.txt.gz",package="Rsubread")
x <- qualityScores(filename=reads,offset=64,nreads=1000)
x[1:10,1:10]
|
qualityScores Rsubread 1.26.1
Scan the input file...
Totally 1000 reads were scanned; the sampling interval is 1.
Now extract read quality information...
Completed successfully. Quality scores for 999 reads (equally spaced in the file) are returned.
1 2 3 4 5 6 7 8 9 10
[1,] 33 33 33 20 20 24 31 15 21 16
[2,] 33 33 30 33 33 30 34 30 32 28
[3,] 32 33 33 32 33 33 33 20 32 24
[4,] 33 33 33 33 33 30 29 34 31 25
[5,] 33 33 33 33 33 34 34 34 33 30
[6,] 33 30 31 24 24 28 33 33 30 32
[7,] 33 33 33 33 30 28 17 25 31 33
[8,] 33 32 2 2 2 2 2 2 2 2
[9,] 33 33 33 34 33 33 31 33 33 33
[10,] 33 33 33 33 28 24 33 33 33 28
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.