Search
Question: Fragen zu Gviz
0
gravatar for florian.hahne@novartis.com
4.7 years ago by
Switzerland
Hi Alexander, see below for some comments. I also CCed the Bioconductor list so others can benefit from it, too. -- From: Alexander Kanitz <alexander.kanitz@unibas.ch<mailto:alexander.kanitz@unibas.ch>> Date: Tuesday, March 19, 2013 6:09 PM To: NIBR <florian.hahne@novartis.com<mailto:florian.hahne@novartis.com>> Subject: Fragen zu Gviz - Can I add thresholds (horizontal ablines e.g. at score 3) into the data tracks? Sure you can. Use the 'baseline' display parameter, e.g., plotTracks(dtTrack, baseline=0.2) - Is it possible to produce upside-down (xy plot) data tracks (to avoid mulitplication by -1)? Or alternatively, can I manually overwrite the y axis labeling with Gviz/R? You can do this by explicitly providing the y axis range via the 'ylims' displayParameter: plotTracks(dtTrack, baseline=0.2, ylim=c(1,0)) Obviously you would need to know about the range of your data ahead of time to do this properly. - Is it possible to increase the distance between strands in the genome axis track ruler to better emphasize the indicated ranges? Could I do this with size (and then reduce lwd, cex etc.)? How does this size parameter work anyway (changes to size didn't seem to have any effect when I tried it)? Yes, indirectly. You can have names for your ranges in the GenomeAxisTrack, and depending on the value of the 'cex.id' parameter Gviz will allocate more space between the axis strands for it: axTrack <- GenomeAxisTrack(name="Axis", range=IRanges::IRanges(start=c(100, 300, 800), end=c(150, 400, 1000), names=1:3)) plotTracks(axTrack, from=0, to=1100, showId=TRUE) plotTracks(axTrack, from=0, to=1100, showId=TRUE, cex.id=2) Now you may not be interested in the ids, and you can make them invisible by setting a transparent color: plotTracks(axTrack, from=0, to=1100, showId=TRUE, cex.id=2, col.id=NA) Also: Is it possible to add more than one GRanges object and/or apply different colors (to individual ranges) within a GenomeAxisTrack? Multiple colors are possible using the fill.range and col.range parameters. If the former one is a vector of equal length as the number of ranges you have provided they will get picked up: plotTracks(axTrack, from=0, to=1100, showId=TRUE, cex.id=2, col.id=NA, fill.range=1:3) plotTracks(axTrack, from=0, to=1100, showId=TRUE, cex.id=2, col.id=NA, fill.range=1:3, col.range=NA) - Since I need to plot whole chromosomes and would therefore like to use the whole width for the ideograms (and the genome axis ruler): Is there another way to plot the chromosome name within Gviz, e.g. a "text track object"? Sure, plotTracks takes a 'main' argument. This adds a general title to your plot: plotTracks(dtTrack, baseline=0.2, ylim=c(1,0), main="This is my plot") Beste Gruesse, Alex -- Alexander Kanitz, Ph.D. Biozentrum University of Basel Klingelbergstrasse 70 4056 Basel Switzerland Phone: +41 61 267 18 86<tel:%2b41%2061%20267%2018%2086> Email: alexander.kanitz@unibas.ch<mailto:alexander.kanitz@unibas.ch> [[alternative HTML version deleted]]
ADD COMMENTlink written 4.7 years ago by florian.hahne@novartis.com1.5k
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.2.0
Traffic: 312 users visited in the last hour