public final class FastqTools extends Object
| Modifier and Type | Method and Description |
|---|---|
static Fastq |
convert(Fastq fastq,
FastqVariant variant)
Convert the specified FASTQ formatted sequence to the
specified FASTQ sequence format variant.
|
static DNASequence |
createDNASequence(Fastq fastq)
Create and return a new
DNASequence from the specified FASTQ formatted sequence. |
static DNASequence |
createDNASequenceWithErrorProbabilities(Fastq fastq)
Create and return a new
DNASequence with error probabilities from the specified
FASTQ formatted sequence. |
static DNASequence |
createDNASequenceWithQualityScores(Fastq fastq)
Create and return a new
DNASequence with quality scores from the specified
FASTQ formatted sequence. |
static DNASequence |
createDNASequenceWithQualityScoresAndErrorProbabilities(Fastq fastq)
Create and return a new
DNASequence with quality scores and error probabilities from the
specified FASTQ formatted sequence. |
static QuantityFeature<AbstractSequence<NucleotideCompound>,NucleotideCompound> |
createErrorProbabilities(Fastq fastq)
Create and return a new
QuantityFeature from the error probabilities of the specified
FASTQ formatted sequence. |
static QualityFeature<AbstractSequence<NucleotideCompound>,NucleotideCompound> |
createQualityScores(Fastq fastq)
Create and return a new
QualityFeature from the quality scores of the specified
FASTQ formatted sequence. |
static Iterable<Number> |
errorProbabilities(Fastq fastq)
Return the error probabilities from the specified FASTQ formatted sequence.
|
static double[] |
errorProbabilities(Fastq fastq,
double[] errorProbabilities)
Copy the error probabilities from the specified FASTQ formatted sequence into the specified double array.
|
static Iterable<Number> |
qualityScores(Fastq fastq)
Return the quality scores from the specified FASTQ formatted sequence.
|
static int[] |
qualityScores(Fastq fastq,
int[] qualityScores)
Copy the quality scores from the specified FASTQ formatted sequence into the specified int array.
|
public static DNASequence createDNASequence(Fastq fastq) throws CompoundNotFoundException
DNASequence from the specified FASTQ formatted sequence.fastq - FASTQ formatted sequence, must not be nullDNASequence from the specified FASTQ formatted sequenceCompoundNotFoundException - if DNA sequence in fastq contains unrecognised compoundspublic static DNASequence createDNASequenceWithQualityScores(Fastq fastq) throws CompoundNotFoundException
DNASequence with quality scores from the specified
FASTQ formatted sequence. The quality scores are stored in a QualityFeature
with a type "qualityScores" the same length as the sequence.fastq - FASTQ formatted sequence, must not be nullDNASequence with quality scores from the specified FASTQ formatted sequenceCompoundNotFoundException - if DNA sequence in fastq contains unrecognised compoundspublic static DNASequence createDNASequenceWithErrorProbabilities(Fastq fastq) throws CompoundNotFoundException
DNASequence with error probabilities from the specified
FASTQ formatted sequence. The error probabilities are stored in a QuantityFeature
with a type "errorProbabilities" the same length as the sequence.fastq - FASTQ formatted sequence, must not be nullDNASequence with error probabilities from the specified FASTQ formatted sequenceCompoundNotFoundException - if DNA sequence in fastq contains unrecognised compoundspublic static DNASequence createDNASequenceWithQualityScoresAndErrorProbabilities(Fastq fastq) throws CompoundNotFoundException
DNASequence with quality scores and error probabilities from the
specified FASTQ formatted sequence. The quality scores are stored in a QualityFeature
with a type "qualityScores" the same length as the sequence and the error
probabilities are stored in a QuantityFeature with a type "errorProbabilities"
the same length as the sequence.fastq - FASTQ formatted sequence, must not be nullDNASequence with quality scores and error probabilities from the specified
FASTQ formatted sequenceCompoundNotFoundException - if DNA sequence in fastq contains unrecognised compoundspublic static QualityFeature<AbstractSequence<NucleotideCompound>,NucleotideCompound> createQualityScores(Fastq fastq)
QualityFeature from the quality scores of the specified
FASTQ formatted sequence. The quality scores feature has a type "qualityScores"
and will be the same length as the sequence.fastq - FASTQ formatted sequence, must not be nullQualityFeature from the quality scores of the specified FASTQ
formatted sequencepublic static QuantityFeature<AbstractSequence<NucleotideCompound>,NucleotideCompound> createErrorProbabilities(Fastq fastq)
QuantityFeature from the error probabilities of the specified
FASTQ formatted sequence. The error probabilities feature has a type "errorProbabilities"
and will be the same length as the sequence.fastq - FASTQ formatted sequence, must not be nullQualityFeature from the error probabilities of the specified FASTQ
formatted sequencepublic static Iterable<Number> qualityScores(Fastq fastq)
fastq - FASTQ formatted sequence, must not be nullpublic static int[] qualityScores(Fastq fastq, int[] qualityScores)
fastq - FASTQ formatted sequence, must not be nullqualityScores - int array of quality scores, must not be null and must be the same
length as the FASTQ formatted sequence qualitypublic static Iterable<Number> errorProbabilities(Fastq fastq)
fastq - FASTQ formatted sequence, must not be nullpublic static double[] errorProbabilities(Fastq fastq, double[] errorProbabilities)
fastq - FASTQ formatted sequence, must not be nullerrorProbabilities - double array of error probabilities, must not be null and must be the same
length as the FASTQ formatted sequence qualitypublic static Fastq convert(Fastq fastq, FastqVariant variant)
fastq - FASTQ formatted sequence, must not be nullvariant - FASTQ sequence format variant, must not be nullCopyright © 2000–2018 BioJava. All rights reserved.