Question: Packages For Visualization Of Biological Data In R
9
gravatar for Malachi Griffith
6.0 years ago by
Washington University School of Medicine, St. Louis, USA
Malachi Griffith16k wrote:

A common task in bioinformatics analysis is the visualization of data, in particular creating figures for manuscripts. I have found R to be incredibly powerful for this task. However, the figures created using many base plotting functions are somewhat 'plain' for publication purposes. This often necessitates additional modification and annotation in Illustrator, Inkscape, etc.

It seems that virtually anything is possible but I'm interested in recommendations for packages/libraries that will help me create richer figures entirely within R.

If you want some specific examples of issues that I have found challenging, these include things like:

  1. legend creation
  2. creation of multi-panel figures with custom margins
  3. addition of unusual 'symbols' to plots (e.g. greek letters, etc.)
  4. use of transparency
  5. more control of fonts

I realize this is a broad question but I am keen to learn about any tricks that will help me push my figures closer to publication quality in R and minimize manual post processing.

R visualization • 7.9k views
ADD COMMENTlink modified 5.9 years ago by Gjain5.1k • written 6.0 years ago by Malachi Griffith16k
1

Similar question: http://biostar.stackexchange.com/questions/18164/how-to-draw-genome-features-along-chromosome

ADD REPLYlink written 6.0 years ago by Sean Davis24k
1

If you want other software or language environments too in addition to R, see the post: http://biostar.stackexchange.com/questions/18390/best-graphics-gallery-or-blogs-for-bioinformatics-use

ADD REPLYlink written 6.0 years ago by John1.4k

good survey/question. It seems we all have the same ones ;-)

ADD REPLYlink written 6.0 years ago by Manu Prestat3.8k
12
gravatar for Gjain
6.0 years ago by
Gjain5.1k
Göttingen, Germany
Gjain5.1k wrote:

Along with the useful libraries and tools mentioned, there are few more that I find useful. Some of them are:

  • Lattice: Multivariate Data Visualization with R

    Lattice brings the proven design of Trellis graphics (originally developed for S by William S. Cleveland and colleagues at Bell Labs) to R, considerably expanding its capabilities in the process. Lattice is a powerful and elegant high level data visualization system that is sufficient for most everyday graphics needs, yet flexible enough to be easily extended to handle demands of cutting edge research.

  • Data visualization (in R)

  • Data analysis and visualisations with googleVis and R

  • GenomeGraphs: integrated genomic data visualization with R:

    GenomeGraphs, as an add-on software package for the statistical programming environment R, to facilitate integrated visualization of genomic datasets. GenomeGraphs uses the biomaRt package to perform on-line annotation queries to Ensembl and translates these to gene/transcript structures in viewports of the grid graphics package.

    It generates graphs like: alt text

I hope this helps.

ADD COMMENTlink written 6.0 years ago by Gjain5.1k

Hej, I'm wondering how to change the labels of the y-axis in this kind of plot? I mean the numeric labels.

makeGenericArray(intensity, start,end,dp=DisplayPars(size=x,color="x"))

ADD REPLYlink written 4.3 years ago by romsen50
9
gravatar for Malachi Griffith
6.0 years ago by
Washington University School of Medicine, St. Louis, USA
Malachi Griffith16k wrote:

Here are some of the things I have found to be useful so far:

  • The R Graph Gallery - a great place to go for inspiration.
  • Bioconductor - often the visualization tools in here are quite specific to a particular type of analysis and can be confusing to customize if you are not getting exactly what you need.
  • ggplot2 - Has a nice tutorial with some pretty examples
  • plotrix - I have not found much in the way of tutorials or examples but it seems promising. To help visualize the kinds of things you get, I created a PDF (PDF portfolio) that contains examples of almost all of the 100+ functions of this package

Plotrix has some nice functions for dealing with legends and labeling of plots but I still could use some advice for the issues I listed in the question.

Any other general packages that I am missing? And specific solutions to my example issues in the question.

ADD COMMENTlink written 6.0 years ago by Malachi Griffith16k

For "good looking" plots, ggplot2 is pretty much all you need.

ADD REPLYlink written 6.0 years ago by Neilfws47k

the plotrix portfolio is very helpful!

ADD REPLYlink written 4.3 years ago by Sebastian Kurscheid300
5
gravatar for Steve Lianoglou
6.0 years ago by
Steve Lianoglou4.8k
US
Steve Lianoglou4.8k wrote:

If you're looking to plot data along a genome, you should check out these two new bioconductor packages

  • Gviz. The plots this thing generates are really beautiful -- have fun browsing the vignette.
  • ggbio. This seems a bit more utilitarian, but also quite nice.

I'm linking to the development versions, because Gviz is only available there for now (soon to be released).

ADD COMMENTlink written 6.0 years ago by Steve Lianoglou4.8k

+1 for Gviz, it looks like a successor to GenomeGraphs. The plots look very professional (more than GenomeGraphs) and publication ready. I will definitely switch to Gviz for visualizing genomic features for papers.

ADD REPLYlink written 5.9 years ago by Michael Dondrup43k
1
gravatar for Obi Griffith
6.0 years ago by
Obi Griffith16k
Washington University, St Louis, USA
Obi Griffith16k wrote:

For "2. creation of multi-panel figures with custom margins" its definitely worth learning to use layout() which seems more powerful than the standard par(mfrow/mfcol) approach. See tutorials here and here. You can arrange figures in almost any layout. The only issue I have had is how to incorporate figures from functions like heatmap.2 which use layout internally onto a multi-plot layout. I.e., Can you have a layout within a layout?

ADD COMMENTlink written 6.0 years ago by Obi Griffith16k
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: 913 users visited in the last hour