how to normalize GC content using cqn function
Hello everyone . I have a count matrix of sequencing data showing how many fragments there is in each region here is a few rows of my data
head(data[,1:6])
[,1] [,2] [,3] [,4] [,5] [,6]
1 3 6 0 0 3 1
2 4 4 0 0 0 0
3 4 4 1 0 2 2
4 0 2 0 0 0 0
5 0 1 0 0 0 0
6 0 5 2 0 0 0
I am trying to GC content normalize my data first I did a quantile normalization with normalize.quantiles function and named output data.norm. then I calculated GC content for each region .Finally using cqn i tried to do GC content normalization
cqn( data.norm, x=gc ,lengths = l)
but I get the following error
Error in qr.default(t(const)) :
NA/NaN/Inf in foreign function call (arg 1)
I'm not familiar with cqn package so I don't exactly know what is the problem here
• 1,577 views
•
link
0 answers
No answers yet.
Log in to answer this question.
What kind of assay is this and why do you think that GC norm. is necessary or beneficial here?
its an ATAC-seq assay. the data shows fragments in each region . I think GC normalization is necessary because in ATAC seq the insertion is usually GC biased.
Is it? I do not know of any paper who has shown this and I do not recall to come across one that in turn showed that GC normalization was beneficial. That was recently asked on SE was well, https://bioinformatics.stackexchange.com/questions/15006/gc-normalization-atac-seq-data and Devon Ryan there answers pretty much the same I would say as well. GC bias normalization has been explored and demonstrated to be beneficial in some cases towards RNA-seq, see this paper from Mike Love (that is the DESeq2 author/maintainer), but not for ATAC-seq. I personally recommend, even if you find a paper who does this, not to adapt these strategies unless there was a credible biostats paper to really investigate this and its implication on the data. It is not commonly done for ATAC-seq (nor ChIP-seq or any other DNA-seq) and I would actually recommend to skip it rather than blindly applying any non-standard normalization. You would probably need to normalize for the GC content of every read/fragment I guess since a peak does not necessarily have the same GC as every read...not trivial all in all. I gave my two cents on how to (relatively simply but properly) normalize ATAC-seq data for something like bedGraph/bigwig-like files in A: ATAC-seq sample normalization (quantil normalization) and for every differential analysis one commonly uses established tools like edgeR, DESeq2 or limma.
I am actually trying to replicate the results for this article: https://www.nature.com/articles/ng.3646 in the methods section authors suggest that after quantile normalization they did a GC content normalization using CQN package. the original data that I am working with is available here : https://www.ncbi.nlm.nih.gov/geo/download/?acc=GSE74912&format=file&file=GSE74912%5FATACseq%5FAll%5FCounts%2Etxt%2Egz
Yes, this is the only paper doing it afaik. I would not do it as outlined above, my preference is described in the post I linked.