Question: I don't know how to make this bioinformatic picture
0
gravatar for younglin113
2.4 years ago by
younglin11350
younglin11350 wrote:

I saw this picture in a recent article. I thought it succinct and I also want to learn to make one. But I don't know what tools I should use to make it. Is there anyone can help me? Here is the picture: TIM 20180512111343

visualization • 661 views
ADD COMMENTlink modified 2.4 years ago by genomax90k • written 2.4 years ago by younglin11350
1

Looks like a screenshot from the UCSC genome browser.

ADD REPLYlink written 2.4 years ago by Devon Ryan96k

Thanks a lot for your answer!!

ADD REPLYlink written 2.4 years ago by younglin11350

Please make sure the link is correct and accessible openly, we can't see it.

ADD REPLYlink written 2.4 years ago by Michael Dondrup47k

sorry, the link has been updated.

ADD REPLYlink written 2.4 years ago by younglin11350
3
gravatar for Alex Reynolds
2.4 years ago by
Alex Reynolds30k
Seattle, WA USA
Alex Reynolds30k wrote:

I posted a Python-based tool on Github called soda.py that creates a web-ready gallery of UCSC browser shots. You just give it your BED file of coordinates, build, and session ID, and you specify an output directory where PDF and PNG results get stored (as well as an index.html file that lets you browse through snapshots with a web browser).

If you want to do things by hand, you can do something like the following quick and dirty approach to get a nice PNG. You'll need ImageMagick convert installed in order to convert the PDF to PNG. You'll also need GNU wget to do web requests on the command line.

$!/bin/bash

chrom="chr1"
chromStart=1234567
chromEnd=1234987
sessionID=1234
genomeBrowserURL="genome.ucsc.edu"
dumpURL="http://${genomeBrowserURL}/cgi-bin/cartDump"
postData="hgsid=${sessionID}&hgt.psOutput=on&cartDump.varName=position&cartDump.newValue=${chrom}%3A${chromStart}-${chromEnd}&submit=submit"
wgetOpts="--no-directories --recursive --convert-links -l 1 -A hgt_*.pdf"
wgetWaitOpts="--wait=1 --random-wait --tries=2 --timeout=100"
wget ${wgetWaitOpts} --post-data "${postData}" "${dumpURL}"
wget ${wgetOpts} ${wgetWaitOpts} "$url&position=${chrom}%3A${chromStart}-${chromEnd}" 2> fetch.log
mv hgt_*.pdf ${sessionID}.pdf
convert -density 300 ${sessionID}.pdf -background white -flatten ${sessionID}.png

You'd fill out chrom, chromStart, chromEnd and sessionID. Or use placeholders $1 etc. and pass them in on the command line.

If you have a few regions to look at, this would just be a matter of modifying this approach to loop over their respective chromosome name and interval values, and naming the output files appropriately. (Or you can use soda.py for automation.)

ADD COMMENTlink written 2.4 years ago by Alex Reynolds30k
1

If your species is not in the UCSC browser, you can make very similar density plots using KaryoploteR: https://bernatgel.github.io/karyoploter_tutorial/

ADD REPLYlink written 2.4 years ago by Philipp Bayer6.8k

It really helps a lot, thanks for your help!

ADD REPLYlink written 2.4 years ago by younglin11350

Please up-vote answers and comments that have helped. Thanks!

ADD REPLYlink written 2.4 years ago by Kevin Blighe65k

You're welcome - happy to help!

ADD REPLYlink written 2.4 years ago by Alex Reynolds30k
0
gravatar for shoujun.gu
2.4 years ago by
shoujun.gu370
Rockville/MD
shoujun.gu370 wrote:

Its a typical genome browser visualization. You can get this kind of visualization in any genome browser.

Under the hood, it’s just a histogram. If you have the data, you can make these plots by any data visualization tools, there are various modules in python, R or JavaScript.

ADD COMMENTlink written 2.4 years ago by shoujun.gu370
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 1252 users visited in the last hour