Skip to content

4.5.8 Coverage

Coverage analysis evaluates how RNA-seq or Ribo-seq density is distributed across normalized transcript regions.

This page documents two related commands:

  1. rpf_Coverage: summarize binned 5' UTR, CDS, and 3' UTR coverage.
  2. rpf_Percent: calculate the percentage of covered positions or density coverage in transcript regions.

rpf_Coverage

Function

rpf_Coverage normalizes transcripts into bins and generates gene-body coverage summaries, line plots, and optional heatmaps or barplots.

Input files

Input Description
Merged density file Usually RIBO_merged.txt or RNA_merged.txt generated by rpf_Merge.
Transcript annotation Normalized transcript annotation file, usually gene.norm.txt.
Binning scheme Number of bins assigned to 5' UTR, CDS, and 3' UTR.

Parameters

Parameter Required Description
-t Yes Input transcript annotation file in TXT format.
-r Yes Input merged density file in TXT format.
-o No Output prefix. If omitted, the script uses its internal prefix handling. Providing this option is recommended.
-f No Reading frame used for coverage calculation. Choices are 0, 1, 2, and all. Default is all.
-m No Retain transcripts with more than this number of RPFs/reads. Default is 50.
-b No Bin numbers for 5' UTR, CDS, and 3' UTR, formatted as utr5,cds,utr3. Default is 30,100,30.
-n No Normalize counts to RPM. Disabled by default.
--thread No Number of threads. Default is 1.
--outlier No Remove outlier genes/transcripts. Disabled by default.
--set No Gene filtering strategy for transcript regions. Choices are intersect and union. Default is union.
--heat No Draw the whole-gene coverage heatmap. Disabled by default.
--bar No Draw the whole-gene coverage barplot. Disabled by default.

Output files

Output Description
<prefix>_mean_coverage.txt Mean binned coverage table used by merge helpers.
<prefix>_coverage.txt Binned coverage table, depending on script output mode.
<prefix>_coverage_line_plot.pdf / <prefix>_coverage_line_plot.png Average coverage line plot.
<prefix>_heat_plot.pdf / <prefix>_heat_plot.png Coverage heatmap when --heat is used.
<prefix>_coverage_bar_plot.pdf / <prefix>_coverage_bar_plot.png Coverage barplot when --bar is used.
<prefix>.log Running log if redirected by the user.

Example

rpf_Coverage \
    -t ../../../1.reference/norm/gene.norm.txt \
    -r ../05.merge/RIBO_merged.txt \
    -o RIBO \
    -m 50 \
    -f all \
    -b 10,150,10 \
    -n \
    --outlier \
    --heat \
    --bar \
    &> RIBO.log

rpf_Percent

Function

rpf_Percent calculates coverage percentage and generates histogram/boxplot summaries for RPF/read coverage.

Input files

Input Description
Merged density file Usually RIBO_merged.txt or RNA_merged.txt.
Transcript annotation Normalized transcript annotation file, usually gene.norm.txt.

Parameters

Parameter Required Description
-t Yes Input transcript annotation file in TXT format.
-r Yes Input merged density file in TXT format.
-o No Output prefix. Providing this option is recommended.
-f No Reading frame used for percentage calculation. Choices are 0, 1, 2, and all. Default is all.
-m No Retain transcripts with more than this number of RPFs/reads. Default is 50.
-n No Normalize counts to RPM. Disabled by default.

Output files

Output Description
<prefix>_coverage_percent.txt Coverage percentage summary table.
<prefix>_coverage_histogram.pdf / <prefix>_coverage_histogram.png Coverage percentage histogram.
<prefix>_coverage_boxplot.pdf / <prefix>_coverage_boxplot.png Coverage percentage boxplot.
<prefix>.log Running log if redirected by the user.

Example

rpf_Percent \
    -t ../../../1.reference/norm/gene.norm.txt \
    -r ../05.merge/RIBO_merged.txt \
    -o RIBO \
    -m 50 \
    -f 0 \
    -n \
    &> RIBO.log

merge_coverage

Merge mean coverage files from multiple samples or analyses.

Parameter Required Description
-l / --list Yes Input coverage files, usually *_mean_coverage.txt. Multiple files can be provided.
-o Yes Output prefix. The output table is <prefix>_mean_coverage.txt.
merge_coverage \
    -l *_mean_coverage.txt \
    -o RIBO

Notes

  • Uniform CDS coverage supports reliable gene-level quantification.
  • Strong 5' or 3' bias may reflect RNA degradation, nuclease bias, mapping artifacts, or library-specific structure.
  • Use consistent binning and filtering settings across samples when comparing coverage profiles.