Find the percentage of bases above a quality threshold
Useful for quality control metrics like Q20 or Q30 percentages.
ASCII quality string
Minimum quality score
Quality encoding scheme
Percentage of bases above threshold (0-100)
const q30Percent = percentAboveThreshold('IIIIIGGGGFFFFF', 30, 'phred33');console.log(`Q30: ${q30Percent.toFixed(1)}%`); // Percentage of Q30+ bases Copy
const q30Percent = percentAboveThreshold('IIIIIGGGGFFFFF', 30, 'phred33');console.log(`Q30: ${q30Percent.toFixed(1)}%`); // Percentage of Q30+ bases
Find the percentage of bases above a quality threshold
Useful for quality control metrics like Q20 or Q30 percentages.