Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

--skipNonCoveredRegions/--skipNAs not working for bigwigCompare in sparse data #1267

Open
jantusan opened this issue Oct 5, 2023 · 0 comments

Comments

@jantusan
Copy link

jantusan commented Oct 5, 2023

Hello,

I have DNA methylation bigwigs with single cytosine resolution and I am trying to reduce the size of the files by averaging the methylation values across bins. I found that bigwigCompare can take the same bigwig twice and average the signal across bins using this command:

$ bigwigCompare --operation mean -b1 wt_CG.bw -b2 wt_CG.bw -o wt_CG_bins.bw

However, methylation data is discontinuous and there may be regions with no cytosines that shouldn't be considered as having zero signal (the default behaviour of Deeptools), so I added the flag --skipNonCoveredRegions. But this gives me the following error:

$ bigwigCompare --operation mean --skipNonCoveredRegions -b1 wt_CG.bw -b2 wt_CG.bw -o wt_CG_bins.bw
[bwClose] There was an error while finishing writing a bigWig file! The output is likely truncated.

I tried using different methylation input file, and two different bigwigs for -b1 and -b2 but I got the same error.

I am not sure if this is limited to sparse data like DNA methylation, but it would be great if the --skipNonCoveredRegions worked as otherwise the methylation level is underestimated on wider regions as a lot of bins with no data in it are now zero.

$ deeptools --version
deeptools 3.1.3
$ python --version
Python 3.8.2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant