Skip to main content
Bioinformatics logoLink to Bioinformatics
. 2025 May 12;41(6):btaf293. doi: 10.1093/bioinformatics/btaf293

GCfix: a fast and accurate fragment length-specific method for correcting GC bias in cell-free DNA

Chowdhury Rafeed Rahman 1,2,, Zhong Wee Poh 3,4, Anders Jacobsen Skanderup 5, Limsoon Wong 6
Editor: Can Alkan
PMCID: PMC12133280  PMID: 40353837

Abstract

Motivation

Cell-free DNA (cfDNA) analysis has wide-ranging clinical applications due to its noninvasive nature. However, cfDNA fragmentomics and copy number analysis can be complicated by GC bias. There is a lack of GC correction software based on rigorous cfDNA GC bias analysis. Furthermore, there is no standardized metric for comparing GC bias correction methods across large sample sets, nor a rigorous experiment setup to demonstrate their effectiveness on cfDNA data at various coverage levels.

Results

We present GCfix, a method for robust GC bias correction in cfDNA data across diverse coverages. Developed following an in-depth analysis of cfDNA GC bias at the region and fragment length levels, GCfix is both fast and accurate. It works on all reference genomes and generates correction factors, tagged BAM files, and corrected coverage tracks. We also introduce two orthogonal performance metrics for (i) comparing the fragment count density distribution of GC content between expected and corrected samples, and (ii) evaluating coverage profile improvement post-correction. GCfix outperforms existing cfDNA GC bias correction methods on these metrics.

Availability and implementation

GCfix software and code for reproducing the figures are publicly accessible on GitHub: https://github.com/Rafeed-bot/GCfix_Software.

Graphical Abstract

graphic file with name btaf293f5.jpg

1 Introduction

Cell-free DNA (cfDNA) is increasingly used as a biomarker in patient monitoring, disease detection, noninvasive prenatal testing, and transplant rejection assessment (Heitzer et al. 2019, Ignatiadis et al. 2021, Lo et al. 2021). Its noninvasive collection from blood and the low cost of shallow whole-genome sequencing (WGS) make cfDNA appealing for clinical applications (Jiang and Lo 2016). For instance, copy number (CN) alteration analysis and fragmentomics based on shallow WGS cfDNA are gaining traction in cancer diagnosis (Adalsteinsson et al. 2017, Mouliere et al. 2018, Cristiano et al. 2019, Zhu et al. 2025) and tissue-of-origin detection (Mouliere et al. 2011, Doebley et al. 2022). These analyses are also increasingly applied to deep WGS samples to quantify circulating tumor DNA (ctDNA) (Zhu et al. 2021). Such methods rely on counting reads or fragments across genomic regions. However, in practice, read counts from a given region depend on its GC content, with sequencing rates typically non-linearly reduced in GC- and AT-rich regions.

This GC bias in cfDNA data arises from biases in priming (Hansen et al. 2010), size selection (Quail et al. 2008), PCR (Kozarewa et al. 2009), and sequencing error likelihood (Nakamura et al. 2011), with PCR as the main contributor (Aird et al. 2011). PCR-free library preparation is impractical for cfDNA due to low DNA input. Factors like sequencing technology, collection tube, processing timing, and library preparation kit further influence GC bias (Browne et al. 2020). This variability hinders the generalizability of algorithms and machine learning models for cfDNA, underscoring the need for effective corrective measures.

GC bias correction methods fall into two main categories: LOESS (Locally Estimated Scatterplot Smoothing)/bin-based and single-position methods. In LOESS methods, the genome is divided into bins, with fragment counts and GC contents calculated per bin. Equal-sized GC bins (Yoon et al. 2009) or a smooth distribution of GC content (Boeva et al. 2011) are assumed, and each genomic bin is assigned to an appropriate GC bin or GC range. The mean fragment count per GC bin or GC content is calculated, and a LOESS curve is generated based on GC bin or GC content versus mean coverage, representing the GC bias across different GC contents. Popular cfDNA tools, such as ichorCNA (Adalsteinsson et al. 2017) (ctDNA quantification), Delfi (Cristiano et al. 2019) (cancer detection and tissue-of-origin identification), and WisecondorX (Raman et al. 2019) (noninvasive prenatal testing) use this approach. Ideally, bin sizes should be under 1 kb, which is feasible only at high sequencing depths. For shallow WGS, larger bins are needed (due to fewer reads), which reduces accuracy; also, the GC bias curve is no longer bell-shaped and bins over 10 kb rarely exceed 55% GC content (Dohm et al. 2008, Benjamini and Speed 2012).

To address these limitations, a single-position GC bias correction method was introduced by Benjamini and Speed (2012). This method uses a sliding GC context window across the reference genome to calculate expected fragment counts for different GC contents. A similar window is applied to each read in a sample, and observed counts are divided by the expected counts to obtain fragment rates for different GC contents. Initially developed for genomic DNA with a narrow fragment length range, this method uses a single GC context window for all fragment lengths. For cfDNA, which has varied fragment lengths, fragment length-specific GC context windows can better estimate GC bias. Griffin (Doebley et al. 2022) applies this approach for cfDNA-based cancer subtyping but requires substantial runtime due to precise GC bias estimation across all positions in the reference genome and sample reads, and it lacks a standalone software package. GCparagon (Spiegl et al. 2023) is an approximation-based single-position method, trading some accuracy for significantly improved speed, and is available as a software. Both Griffin and GCparagon build on genomic DNA GC bias studies (Benjamini and Speed 2012) but target cfDNA. Neither provides performance metrics for large sample evaluations, and both are limited to a single reference genome without comprehensive testing on cfDNA samples of varying coverage.

We propose GCfix, a cfDNA GC bias correction software based on precise, fragment length-specific single-position GC bias estimation. GCfix offers greater accuracy than Griffin, faster performance than GCparagon, and compatibility with all reference genomes. We introduce two orthogonal performance metrics for large-scale evaluation: the divergence metric, assessing corrected GC content fragment counts against expected distributions; and the variation metric, measuring coverage consistency across regions with similar CNs post-correction. GCfix is evaluated on four cohorts—two healthy (Zhu et al. 2025), one colon, and one breast cancer (Zhu et al. 2021)—across coverages from over 30× to 0.1× WGS. Finally, we show GCfix’s efficacy in enhancing ctDNA fraction prediction, fetal fraction estimation, and coverage consistency in gene promoter transcription start site (TSS) regions.

2 Materials and methods

An overview of GCfix is provided in Fig. 1. Each step has been optimized for runtime and tailored based on the cfDNA GC bias analysis shown in Fig. 2 and Figs 1–3, available as supplementary data at Bioinformatics online.

Figure 1.

Figure 1.

Overview of GCfix correction process.

Figure 2.

Figure 2.

cfDNA GC bias investigation. (a) The noisy base density at start and end positions of 150 bp length fragments (top). The noise disappears when 10 bp is clipped from the start and end of the fragment (bottom). (b) Working with 101 fixed GC content bins irrespective of fragment length can render missing GC content bins for short fragments; this can easily be solved via linear interpolation. (c) Fragments within ±2 bp length range generally exhibit similar GC bias curves for the same sample. (d) cfDNA GC bias in the same sample does not vary from chromosome to chromosome. (e) Estimated GC bias curves using whole genome, neutral regions and copy number variation regions look similar for the same cancer sample. (f) There is a clear shift in fragment length GC bias curves while moving from short to long fragments of the same sample.

2.1 Input

GCfix requires a reference genome, valid genomic regions, and a sample’s BAM file as input. The reference genome provides expected fragment counts for different GC contents. Analysis is limited to valid genomic regions, excluding blacklisted, low mappability, low base-quality, and other marked unusual regions. The sample BAM file provides observed fragment counts across different GC contents by referencing sample reads mapped to the reference genome. By default, GCfix operates on fragments between 51 and 400 bp, which covers a majority of cfDNA fragments; other ranges can be specified as needed.

2.2 Fragment counting

2.2.1 Expected and observed fragment count

We obtain counts for 101 GC content bins (0%, 1%, 2%, …, 100%) for fragments of length 51–400 bp (by default), resulting in a matrix of size 350×101 for both expected and observed settings. Figure 2a shows noisy base density at the first and last 10 bp for fragments of length 150, a pattern consistently seen across all fragment lengths (Fig. 1, available as supplementary data at Bioinformatics online) in both healthy and cancer samples. Thus, analogous to the work done by Benjamini and Speed (2012), for each fragment length, the GC context window is defined to exclude the first and last 10 bp of the fragment to avoid the noise in these positions. Only forward reads are counted, excluding duplicates, supplementary, and unpaired reads. The GC content of each fragment is defined by dividing the count of G and C nucleotides in its GC context window by the window’s size. Fragments are then assigned into the GC content bins according to their length and GC content. For observed counts, the GC context windows of valid reads in the sample are used. For expected counts, the GC context window is slid across all valid positions in the reference genome (Data 4, available as supplementary data at Bioinformatics online).

2.2.2 Count interpolation for GC content gaps

As noted, we use 101 fixed GC content bins regardless of fragment length. This setup allows the expected and observed counts to be represented as uniform two-dimensional NumPy arrays, enabling parallel processing and SIMD (Single Instruction, Multiple Data) operations during GC bias estimation. However, using a fixed number of GC content bins can lead to gaps in observed and expected counts, especially for shorter fragments at smaller GC context sizes. The left plot of Fig. 2b displays observed fragment counts for 80 bp fragments at a 60 bp GC context size, where only 60 out of 101 GC content bins are filled. To address this, linear interpolation using neighboring non-zero GC content counts is applied, as shown in the right part of Fig. 2b.

2.2.3 Merging neighboring fragment counts

When analyzing raw GC bias curves for different fragment lengths, we observe that fragments within ±2 bp in length exhibit similar GC bias curves; cf. Fig. 2c. For each fragment length, we merge its counts with those within ±2 bp in the same GC content bin, both for observed and expected counts. This allows us to estimate accurate GC correction factors per fragment length, even in ultra-low-pass (ulp) WGS samples.

2.3 GC bias estimation

2.3.1 Fragment rate calculation

Fragment rates are estimated for each GC content bin and fragment length by dividing the observed count by the expected count. We extract GC bias values for the 10%–90% GC content range, encompassing over 99.5% of the sample fragments. To minimize noise, we replace values below the third percentile with the third percentile, and values above the 97th percentile with the 97th percentile, of the obtained GC bias values.

2.3.2 Normalization and smoothing

We perform mean normalization on the denoised fragment rates across all GC content bins for each fragment length separately. Next, we apply LOESS smoothing using a smoothing factor of 0.1 for each fragment length and retain only the 20%–80% GC content range, which covers about 99% of the sample fragments. Previously, we extracted the 10%–90% GC content range to assist the smoothing process for our target range, which is 20%–80%. Finally, we conduct mean normalization at the fragment length level one last time to obtain the final GC bias values.

Our analysis shows no major differences in chromosome-specific GC bias curves in the same sample, cf. Fig. 2d, so we do not differentiate between genomic regions of the same sample during GC bias estimation. Although it was suggested by Benjamini and Speed (2012) that including copy number variation (CNV) regions could confound GC bias estimation, we observe minimal differences in GC bias curves estimated across all fragments in CNV regions, neutral regions, and the whole genome for the same cancer sample; see Fig. 2e. Similar analysis per fragment length confirms consistent GC bias curves for CNV, neutral, and whole-genome regions (Fig. 2, available as supplementary data at Bioinformatics online). This consistency across colon and breast cancer samples from two cohorts supports the inclusion of all valid regions, including CNV regions, in GC bias estimation.

Examining the GC bias curves for individual fragment lengths ranging from 51 to 400 bp, we observe a shift from a gradually increasing curve to bell curve after 80 bp, a transition from a bell curve to a gradually increasing curve after 220 bp, and another shift from a gradually increasing curve to a bell curve after 300 bp; cf. Fig. 2f. This pattern is consistent across both healthy and cancer samples from different cohorts (Fig. 3, available as supplementary data at Bioinformatics online), highlighting the importance of estimating GC bias at fragment length level for cfDNA data.

2.4 Correction factor estimation

Fragments with a GC bias value greater than 1 are overrepresented and should be down-weighted, while those with a GC bias value less than 1 should be up-weighted. Thus, the correction factor is the inverse of the estimated GC bias values for different fragment lengths and GC content bins. We estimate GC bias only for the 20%–80% GC content range, setting correction factors for bins outside of this range to 0. To ensure that no correction factor exceeds 20, we apply a maximum threshold. However, if the 99th percentile of correction factors for a sample exceeds 20, we set the maximum threshold to this percentile, assuming the sample has significant initial GC bias.

2.5 Output

GCfix generates three output files for a single input sample BAM file: (i) a CSV file containing GC bias correction factors for various fragment lengths (rows) and different GC contents (columns); (ii) a tagged BAM file with the GC bias correction factor for each read as a “GC” tag; and (iii) a CSV file listing genomic bins and their corresponding corrected read counts.

3 Experiment results

3.1 Dataset description

All samples in this study are obtained from works done by Zhu et al. (2021, 2025). The evaluation plots in Figs 3 and 4b and c represent four deep WGS (over 30×) cohorts: (i) two healthy cohorts with 12 and 17 samples; (ii) one colon cancer cohort with 12 samples; and (iii) one breast cancer cohort with 10 samples. These samples are downsampled to lower coverages (down to 0.1×) using SAMtools for GC bias correction testing in shallow WGS. Figure 4a features lpWGS samples from five cohorts: (i) three healthy cohorts with 12, 17, and 28 samples; (ii) 86 colon cancer samples; and (iii) 10 breast cancer samples with available variant allele frequency (VAF).

Figure 3.

Figure 3.

GCfix performance evaluation. (a) Shift in the GC content fragment frequency density distribution of original sample towards the expected distribution following GCfix correction for different fragment length groups. (b) Mean Jensen Shannon (JS) divergence from the expected GC content fragment frequency density distribution, across all samples, before (original) and after correction using three different methods across various coverages for different fragment lengths. (c) Coverage profile before and after GCfix correction for different contigs in cancer and healthy samples. (d) Mean coefficient of variation (COV) across similar CNV regions for all samples, before and after coverage profile correction using three different methods across various coverages for fragments ranging from 51 to 400 bp. The left and right subfigures use 100 kb and 1 Mb bins in COV calculation, respectively. (e) Runtime comparison between GCfix, Griffin, and GCparagon for generating GC bias correction factors across samples of varying coverages.

Figure 4.

Figure 4.

GCfix applications. (a) Enhanced ichorCNA performance in ctDNA quantification and cancer detection. (b) Improved simulated fetal fraction estimation. (c) Increased consistency of NDR score (derived from gene promoter TSS regions) across samples within the same gene expression group, and better separation between different gene expression groups.

3.2 Jensen Shannon divergence

Jensen Shannon (JS) divergence (Endres and Schindelin 2003) measures “distance” between two probability distributions, where a lower score indicates greater similarity (Data 5, available as supplementary data at Bioinformatics online). Let us look at the second plot (from the left) in Fig. 3a to understand more on how this metric is being used. The red curve is constructed by counting the total number of 51–100 bp length fragments for different GC contents in an uncorrected sample and then by converting those counts into sum normalized density (probability distribution). The green curve is constructed in the same way for the GCfix GC bias corrected version of the same sample. The blue curve is constructed from the reference genome by obtaining expected counts (Data 4, available as supplementary data at Bioinformatics online) of 51–100 bp length fragments for different GC contents and then by converting those counts into sum normalized density (probability distribution). If there were no GC bias, then the red curve (uncorrected original curve) would coincide with the blue expected curve, and the JS divergence between the red (original) and the blue (expected) curve would be 0. But we can see that there is a large distance between these two curves rendering a JS score of 0.18. On the other hand, the green curve obtained from the same sample after GCfix correction comes much closer to the expected blue curve rendering a small JS score of only 0.03. Figure 3a shows this same phenomenon for four different fragment length groups of the same sample.

Figure 3b illustrates the mean JS divergence across all samples for different fragment length groups and coverages. GCfix significantly reduces divergence for all length groups and coverages compared to the original and other correction methods. Notably, the JS divergence for Griffin appears worse than uncorrected distributions for some length groups below 1× coverage. On the other hand, GCparagon shows minimal change in divergence scores for short and long fragments. Figures 4 and 5, available as supplementary data at Bioinformatics online, present boxplots comparing JS divergence scores for deep WGS and ulpWGS (0.1×) samples, confirming similar conclusions as in Fig. 3b.

3.3 Coefficient of variation

Bins within the same genomic region and sharing a similar CN label (neutral/gain/loss) should exhibit comparable normalized coverage, barring any GC bias effects. Such a “run of bins” should have a low coefficient of variation (COV) for their normalized coverages, indicating that the standard deviation (SD) of these coverages is low relative to their mean. For healthy samples, all bins are expected to be neutral regarding CNV. In cancer samples, we use only bins with high confidence CNV calls from ichorCNA. A CNV call is deemed high confidence under three conditions: (i) for neutral calls, CN should be between 1.5 and 2.5; (ii) for gain/amplified/highly amplified calls, CN must exceed 2.5; and (iii) for homozygous/heterozygous deletion calls, CN should be below 1.5. We analyze runs of 100 kb bins (1 Mb for 0.1× WGS) across the genome and calculate the COV for each run. The mean of these COVs is the sample COV. Each bin run has three properties: (i) it contains 50 consecutive 100 kb bins (or 10 consecutive 1 Mb bins for 0.1× WGS); (ii) all bins in a run share the same label (neutral/gain/loss); and (iii) each run is at least 25 100 kb bins (or five 1 Mb bins for 0.1× WGS) apart from the immediate previous run.

Figure 3c shows a significant reduction of COV for healthy and cancer samples in both neutral and CNV regions after GCfix correction. Figure 3d displays the mean COV (across all samples) for original and corrected coverage profiles using different methods across various coverages. At 10× and higher coverage, Griffin and GCfix exhibit comparable mean COV, while GCparagon lags behind. However, Griffin performance drops significantly below 2× WGS, with its COV worse than the original for 0.1× WGS samples and similar to the original for 0.5× WGS. Figure 13, available as supplementary data at Bioinformatics online, visually shows how Griffin disrupts the original coverage profile for 0.1× WGS samples, while GCfix improves consistency in the same coverage profile.

Low-pass WGS (lpWGS) cfDNA sequencing is widely used for analyzing genomic CN alterations (Adalsteinsson et al. 2017, Hovelson et al. 2017, Chen et al. 2019, Smolander et al. 2021), making effective coverage correction on lpWGS samples crucial. Figures 6 and 7, available as supplementary data at Bioinformatics online, are boxplots of COV scores for deep WGS and ulpWGS (0.1×) samples across the different correction methods, supporting the conclusions from Fig. 3d. Figure 6, available as supplementary data at Bioinformatics online, shows COV boxplots for various fragment length groups, revealing that GCparagon does not improve COV for short fragments (51–100 bp). Figure 12, available as supplementary data at Bioinformatics online, provides visual evidence of this, comparing short fragment coverage profiles before and after GCparagon correction & GCfix correction. GCfix performs well across all fragment lengths and coverages.

3.4 Runtime comparison

Figure 3e compares the runtime between GCfix, Griffin, and GCparagon for samples of different coverages. The runtimes have been measured in second and have been log scaled for ease of visualization. GCfix is over 40 times faster than Griffin for both deep and lpWGS data while consuming a similar amount of memory (around 20 Mb). In contrast, GCparagon randomly samples around 50 million reads (equivalent to 5× WGS) for each sample, regardless of coverage, to estimate GC bias, which makes it extremely fast. Although GCfix uses all reads to accurately estimate GC bias, it is faster than GCparagon up to 30× deep WGS coverage.

GCfix takes only around 5 min to estimate GC correction factors from a 50× deep WGS BAM file. This speed can be further improved if we approximate the GC correction factors through subsampling smaller number of reads from the deep WGS sample. Our proposed COV metric deteriorates for GCfix as we move toward lower coverage samples (Fig. 3d). As a result, we have not applied this subsampling, considering that GCfix is already fast.

3.5 GCfix versus GC%-only GCfix

GCfix estimates one GC bias curve for each fragment length of a sample. This is done by using a length-dependent GC context size during GC bias estimation. We experiment with a GC%-only GCfix variant that estimates GC correction factors for different GC content levels, regardless of fragment length. A fixed GC context size of 400 (cfDNA fragment length typically ranges between 51 and 400 bp; so size 400 covers even the longest length fragments) is used beginning from the fragment start position during GC bias estimation, regardless of fragment length. While the JS divergence score for this length-agnostic GCfix variant is better than uncorrected original cfDNA samples, it is significantly worse than the original GCfix (Fig. 9a, available as supplementary data at Bioinformatics online). Same pattern can be seen for the COV metric (Fig. 9b, available as supplementary data at Bioinformatics online). Figure 2f shows how the GC bias curves for the different fragment lengths of the same sample can be significantly different from one another. As a result, a length-agnostic GCfix achieves sub-optimal performance compared to the original GCfix.

4 GCfix applications

4.1 ichorCNA performance improvement

cfDNA-based cancer detection (Mouliere et al. 2018, Cristiano et al. 2019) and tumor fraction quantification (Adalsteinsson et al. 2017, Zhu et al. 2025) have recently gained traction with lpWGS cfDNA data. This study examines the impact of GCfix on the ctDNA quantification software ichorCNA (Adalsteinsson et al. 2017).

ichorCNA models CN states across the genome using a hidden Markov model (HMM) (Rabiner 1989) on a wig file containing read count of 1 Mb bins. We generated a corrected wig file using GCfix for each sample and applied ichorCNA method to estimate the ctDNA fraction. As shown in Fig. 4a, GCfix enhances the correlation between ichorCNA-estimated ctDNA fraction (based on lpWGS) and maximum VAF for both colon and breast cancer samples. Also, Youden’s index (Youden 1950) and auROC score (Hanley and McNeil 1982) for cancer and healthy sample discrimination are improved following GCfix correction (all relevant plots provided in Fig. 10, available as supplementary data at Bioinformatics online).

4.2 Improvement in fetal fraction estimation

Cost-effective noninvasive prenatal testing (NIPT) relies on lpWGS sequencing of maternal DNA (Yu et al. 2019). We simulated fetal fraction estimation using two lpWGS BAM files—one for female and one for male. Each file was downsampled to have a similar number of fragments. We took X% reads from the male BAM file and merged them with the full female BAM file to create a new merged BAM representing a pregnant female where there was a male fetus inside with (XX+100)×100% fetal fraction. The task here is to estimate this fetal fraction by analyzing read counts of each autosome inside the merged BAM file.

We obtained 22 fetal fraction estimates (detailed in Data 1, available as supplementary data at Bioinformatics online) from the 22 autosome pairs and calculated their mean as the final estimate. We tested healthy female (mother) and male (fetus) samples from both the same cohort and different cohorts, varying X% as 5% and 10% to represent the ground truth fetal fraction of around 4.76% and 9.09%, respectively. Figure 4b(left) shows the improvement in mean absolute error (MAE) of estimated fetal fractions after applying GCfix correction to the female pregnant BAM. The SD of the 22 estimations also significantly decreased post-correction. In Fig. 4b (right), we analyzed the mapped read count-to-autosome length ratio for all 22 autosomes within each sample, calculating SD (ideally, SD should be 0). The results indicate that after GCfix correction, the SD reduces by around 50% for all samples, explaining the improved estimation accuracy.

4.3 Improvement in NDR coverage profile

The relative coverage at nucleosome-depleted regions (NDRs) around TSSs is associated with gene expression. We examine the coverage profile and NDR score (Zhu et al. 2021) of gene promoter TSS regions obtained from the Matched Annotation from NCBI and EMBL-EBI (MANE) database. NDRs are defined as the −150 to +50 bp window around the TSS, while flanking regions span −1000 bp to −2000 bp upstream and 1000–2000 bp downstream. Each TSS’s NDR score is calculated by dividing the mean coverage within the TSS region by the mean coverage in the flanking regions.

We analyzed NDR scores for 17 deep WGS healthy cfDNA TSS regions across gene expression levels from GTEx Whole Blood RNA-Seq before and after GCfix correction; cf. Fig. 4c. Each boxplot point represents the mean NDR score of all NDRs in a single sample for a given gene expression group measured in TPM (transcripts per million). As shown, NDR score variance within each expression group decreases substantially post-GCfix, yielding a statistically significant lower NDR score for each higher expression group compared to the immediate previous expression group (one-sided Wilcoxon rank sum test). Further, examining relative coverage (Data 2, available as supplementary data at Bioinformatics online) of ±2000 bp region relative to each TSS position, GCfix correction markedly reduces variance in relative coverage profile within each gene expression group for the deep WGS healthy cfDNA samples (Fig. 11, available as supplementary data at Bioinformatics online). The potential for NDR coverage improvement through GC correction was first discussed by Poh et al. (2025) for deep WGS colon cancer samples.

5 Discussion and concluding remarks

Benjamini and Speed (2012) demonstrated single-position GC bias correction methods outperforming LOESS/bin-based methods, leading to Griffin’s fragment-length-specific single-position method for cfDNA GC bias correction. However, Griffin has a high runtime (see Section 3.4), performs poorly on shallow sequencing data, and is not user-friendly. It requires users to generate precomputed GC frequency files for their reference genome and lacks a tagged BAM output for convenient correction factor access. Users must consult multiple files and the read GC context to retrieve correction factors. Also, Griffin often produces NAN and 0 values as the estimated GC bias for some GC count and fragment length combinations due to insufficient post-processing of GC bias estimates. GCparagon builds on Griffin’s principles but uses sampling-based approximation to speed up correction factor generation, and is available as a software specifically for hg19. While it provides BAM tagging with correction factors, the sequential tagging process is slow. GCparagon’s weakness is its limited correction for short and long cfDNA fragments; cf. the flat GCparagon curves in Fig. 14, available as supplementary data at Bioinformatics online. Fragment counts before and after GCparagon correction change by <1% (Fig. 8, available as supplementary data at Bioinformatics online) because its correction factors are near 1, indicating conservative correction. As GCparagon estimates GC bias from a small subset of reads regardless of coverage, its GC bias correction performance on moderately high-coverage samples is weaker than both GCfix and Griffin. Algorithmic differences between GCfix, Griffin, and GCparagon are detailed in Data 3, available as supplementary data at Bioinformatics online.

GCfix addresses the issues above by efficiently using all reads in a sample BAM file to accurately estimate GC bias. It outperforms both Griffin and GCparagon across different sequencing coverages, as demonstrated using two performance metrics proposed here—JS divergence and COV. GCfix is also effective in applications such as ctDNA quantification, fetal fraction estimation, and TSS coverage profile improvement. Designed for ease of use, GCfix is compatible with all reference genomes and tags BAM reads with correction factors quickly (about 5 min for 1× WGS) by breaking BAM files into chunks, and tagging them in parallel. Users can specify the genomic regions for tagging, enhancing efficiency, or request corrected read counts for specific regions without needing expertise in GC bias correction. We expect GCfix to have broad applications across various research and clinical domains.

Supplementary Material

btaf293_Supplementary_Data

Contributor Information

Chowdhury Rafeed Rahman, Genome Institute of Singapore (GIS), Agency for Science, Technology and Research (A*STAR), 138672, Singapore; School of Computing, National University of Singapore, 117417, Singapore.

Zhong Wee Poh, Genome Institute of Singapore (GIS), Agency for Science, Technology and Research (A*STAR), 138672, Singapore; School of Computing, National University of Singapore, 117417, Singapore.

Anders Jacobsen Skanderup, Genome Institute of Singapore (GIS), Agency for Science, Technology and Research (A*STAR), 138672, Singapore.

Limsoon Wong, School of Computing, National University of Singapore, 117417, Singapore.

Author contributions

Rafeed Chowdhury (Conceptualization [lead], Data curation [supporting], Formal analysis [lead], Investigation [lead], Methodology [lead], Software [lead], Validation [lead], Visualization [lead], Writing—original draft [lead]), Poh Wee (Data curation [supporting], Investigation [supporting], Validation [supporting], Visualization [supporting]), Anders Skanderup (Conceptualization [supporting], Data curation [lead], Funding acquisition [lead], Methodology [supporting], Project administration [supporting], Resources [lead], Software [supporting], Supervision [supporting]), and Limsoon Wong (Conceptualization [supporting], Formal analysis [supporting], Investigation [supporting], Methodology [supporting], Project administration [lead], Supervision [lead], Writing—review & editing [lead])

Supplementary data

Supplementary data are available at Bioinformatics online.

Conflict of interest: The authors declare no conflict of interest.

Funding

This work was supported by Singapore Ministry of Health’s National Medical Research Council under its OF-IRG program [OFIRG21nov-0083].

Data availability

The proposed GCfix software can be found in GitHub: https://github.com/Rafeed-bot/GCfix_Software. All code and data to reproduce the figures of the paper can be found in zenodo: https://zenodo.org/records/14910072 (DOI: 10.5281/zenodo.14910072).

References

  1. Adalsteinsson VA, Ha G, Freeman SS  et al.  Scalable whole-exome sequencing of cell-free DNA reveals high concordance with metastatic tumors. Nat Commun  2017;8:1324. [DOI] [PMC free article] [PubMed] [Google Scholar]
  2. Aird D, Ross MG, Chen W-S  et al.  Analyzing and minimizing PCR amplification bias in illumina sequencing libraries. Genome Biol  2011;12:R18–14. [DOI] [PMC free article] [PubMed] [Google Scholar]
  3. Benjamini Y, Speed TP.  Summarizing and correcting the GC content bias in high-throughput sequencing. Nucleic Acids Res  2012;40:e72. [DOI] [PMC free article] [PubMed] [Google Scholar]
  4. Boeva V, Zinovyev A, Bleakley K  et al.  Control-free calling of copy number alterations in deep-sequencing data using GC-content normalization. Bioinformatics  2011;27:268–9. [DOI] [PMC free article] [PubMed] [Google Scholar]
  5. Browne PD, Nielsen TK, Kot W  et al.  GC bias affects genomic and metagenomic reconstructions, underrepresenting GC-poor organisms. Gigascience  2020;9:giaa008. [DOI] [PMC free article] [PubMed] [Google Scholar]
  6. Chen X, Chang C-W, Spoerke JM  et al.  Low-pass whole-genome sequencing of circulating cell-free DNA demonstrates dynamic changes in genomic copy number in a squamous lung cancer clinical cohort. Clin Cancer Res  2019;25:2254–63. [DOI] [PubMed] [Google Scholar]
  7. Cristiano S, Leal A, Phallen J  et al.  Genome-wide cell-free DNA fragmentation in patients with cancer. Nature  2019;570:385–9. [DOI] [PMC free article] [PubMed] [Google Scholar]
  8. Doebley A-L, Ko M, Liao H  et al.  A framework for clinical cancer subtyping from nucleosome profiling of cell-free DNA. Nat Commun  2022;13:7475. [DOI] [PMC free article] [PubMed] [Google Scholar]
  9. Dohm JC, Lottaz C, Borodina T  et al.  Substantial biases in ultra-short read data sets from high-throughput DNA sequencing. Nucleic Acids Res  2008;36:e105. [DOI] [PMC free article] [PubMed] [Google Scholar]
  10. Endres DM, Schindelin JE.  A new metric for probability distributions. IEEE Trans Inform Theory  2003;49:1858–60. [Google Scholar]
  11. Hanley JA, McNeil BJ.  The meaning and use of the area under a receiver operating characteristic (ROC) curve. Radiology  1982;143:29–36. [DOI] [PubMed] [Google Scholar]
  12. Hansen KD, Brenner SE, Dudoit S.  Biases in illumina transcriptome sequencing caused by random hexamer priming. Nucleic Acids Res  2010;38:e131. [DOI] [PMC free article] [PubMed] [Google Scholar]
  13. Heitzer E, Haque IS, Roberts CES  et al.  Current and future perspectives of liquid biopsies in genomics-driven oncology. Nat Rev Genet  2019;20:71–88. [DOI] [PubMed] [Google Scholar]
  14. Hovelson DH, Liu C-J, Wang Y  et al.  Rapid, ultra low coverage copy number profiling of cell-free DNA as a precision oncology screening strategy. Oncotarget  2017;8:89848–66. [DOI] [PMC free article] [PubMed] [Google Scholar]
  15. Ignatiadis M, Sledge GW, Jeffrey SS.  Liquid biopsy enters the clinical: implementation issues and future challenges. Nat Rev Clin Oncol  2021;18:297–312. [DOI] [PubMed] [Google Scholar]
  16. Jiang P, Lo YMD.  The long and short of circulating cell-free DNA and the ins and outs of molecular diagnostics. Trends Genet  2016;32:360–71. [DOI] [PubMed] [Google Scholar]
  17. Kozarewa I, Ning Z, Quail MA  et al.  Amplification-free illumina sequencing-library preparation facilitates improved mapping and assembly of (G+C)-biased genomes. Nat Methods  2009;6:291–5. [DOI] [PMC free article] [PubMed] [Google Scholar]
  18. Lo YMD, Han DSC, Jiang P  et al.  Epigenetics, fragmentomics, and topology of cell-free DNA in liquid biopsies. Science  2021;372:eaaw3616. [DOI] [PubMed] [Google Scholar]
  19. Mouliere F, Robert B, Arnau Peyrotte E  et al.  High fragmentation characterizes tumour-derived circulating DNA. PLoS One  2011;6:e23418. [DOI] [PMC free article] [PubMed] [Google Scholar]
  20. Mouliere F, Chandrananda D, Piskorz AM  et al.  Enhanced detection of circulating tumor DNA by fragment size analysis. Sci Transl Med  2018;10:eaat4921. [DOI] [PMC free article] [PubMed] [Google Scholar]
  21. Nakamura K, Oshima T, Morimoto T  et al.  Sequence-specific error profile of illumina sequencers. Nucleic Acids Res  2011;39:e90. [DOI] [PMC free article] [PubMed] [Google Scholar]
  22. Poh ZW, Zhu G, Mun Wong P  et al. A computational framework for analysis of cfDNA fragmentation profiles. bioRxiv, 10.1101/2025.04.17.649313,  2025, preprint: not peer reviewed. [DOI]
  23. Quail MA, Kozarewa I, Smith F  et al.  A large genome center’s improvements to the illumina sequencing system. Nat Methods  2008;5:1005–10. [DOI] [PMC free article] [PubMed] [Google Scholar]
  24. Rabiner LR.  A tutorial on hidden Markov models and selected applications in speech recognition. Proc IEEE  1989;77:257–86. [Google Scholar]
  25. Raman L, Dheedene A, De Smet M  et al.  WisecondorX: improved copy number detection for routine shallow whole-genome sequencing. Nucleic Acids Res  2019;47:1605–14. [DOI] [PMC free article] [PubMed] [Google Scholar]
  26. Smolander J, Khan S, Singaravelu K  et al.  Evaluation of tools for identifying large copy number variations from ultra-low-coverage whole-genome sequencing data. BMC Genom  2021;22:357. [DOI] [PMC free article] [PubMed] [Google Scholar]
  27. Spiegl B, Kapidzic F, Röner S  et al.  GCparagon: evaluating and correcting GC biases in cell-free DNA at the fragment level. NAR Genom Bioinform  2023;5:lqad102. [DOI] [PMC free article] [PubMed] [Google Scholar]
  28. Yoon S, Xuan Z, Makarov V  et al.  Sensitive and accurate detection of copy number variants using read depth of coverage. Genome Res  2009;19:1586–92. [DOI] [PMC free article] [PubMed] [Google Scholar]
  29. Youden WJ.  Index for rating diagnostic tests. Cancer  1950;3:32–5. [DOI] [PubMed] [Google Scholar]
  30. Yu D, Zhang K, Han M  et al.  Noninvasive prenatal testing for fetal subchromosomal copy number variations and chromosomal aneuploidy by low-pass whole-genome sequencing. Mol Genet Genomic Med  2019;7:e674. [DOI] [PMC free article] [PubMed] [Google Scholar]
  31. Zhu G, Guo YA, Ho D  et al.  Tissue-specific cell-free DNA degradation quantifies circulating tumor DNA burden. Nat Commun  2021;12:2229. [DOI] [PMC free article] [PubMed] [Google Scholar]
  32. Zhu G, Rahman CR, Getty V  et al.  A deep-learning model for quantifying circulating tumour DNA from the density distribution of DNA-fragment lengths. Nat Biomed Eng  2025;9:1–13. [DOI] [PubMed] [Google Scholar]

Associated Data

This section collects any data citations, data availability statements, or supplementary materials included in this article.

Supplementary Materials

btaf293_Supplementary_Data

Data Availability Statement

The proposed GCfix software can be found in GitHub: https://github.com/Rafeed-bot/GCfix_Software. All code and data to reproduce the figures of the paper can be found in zenodo: https://zenodo.org/records/14910072 (DOI: 10.5281/zenodo.14910072).


Articles from Bioinformatics are provided here courtesy of Oxford University Press

RESOURCES