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

plot.dist.py output to screen only #178

Open
space-beaver opened this issue Jul 1, 2022 · 4 comments
Open

plot.dist.py output to screen only #178

space-beaver opened this issue Jul 1, 2022 · 4 comments

Comments

@space-beaver
Copy link

space-beaver commented Jul 1, 2022

I've calculated mosdepth coverage with the command:

mosdepth -n -b 500 -x -t 4 -Q30 $OUTPUT_DIR/${base%.cov} ${this_bam}

I run plot-dist.py with:

python mosdepth-0.3.3/scripts/plot-dist.py *.global.dist.txt

However, the output prints to screen and an empty html is created. Is there something I'm doing wrong? Output file attached. TIA.

example.mosdepth.global.dist.txt

@brentp
Copy link
Owner

brentp commented Jul 1, 2022

Hi, you have many chromosomes in there so the html output just gets too big. You can get more reasonable output with:

grep -v ^NW example.mosdepth.global.dist.txt > subset.mosdepth.global.dist.txt

then use plot-dist.py on that.

@space-beaver
Copy link
Author

Solved, many thanks. Is there a way to shift the legend to the right, or easiest just to turn off?

@brentp
Copy link
Owner

brentp commented Jul 1, 2022

You can probably edit plot_dist.py to do that, it's really just meant as an example. You can also use multiqc on the mosdepth output to get nicer plots.

@Rohit-Satyam
Copy link

Actually Multiqc does produce nicer plots. Thanks for recommendation!!

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

3 participants