Creating Sequence Logos From The Command Line
7
6
Entering edit mode
13.2 years ago
Qdjm 1.9k

What's your favourite way to create sequence logos from the command line or programmatically?

This is in response to a question at StackOverflow on making sequence logos in ggplot2. I looked here and was surprised that couldn't find the answer.

Ideally, the package would be easy to use but flexible enough to show different logo representations (e.g. scale height by frequency or by information content) and different alphabets (DNA, RNA, and amino acids).

We have our own way of doing this in the lab, and being a PI, I don't know what it is, but I would like to hear other options.

sequence visualization motif • 9.5k views
ADD COMMENT
0
Entering edit mode

if you want i can provide the sourcecode of my way of doing it (see my answer). However it might be a bif different of our approach as I use Perl scripts to build position weight matrices.

ADD REPLY
7
Entering edit mode
13.2 years ago

There are some well-known problems with sequence logos, namely that the most frequent nucleotide gets top billing even if it is only a fraction more frequent than the runner-up.

Charles Berry developed an alternative that mitigates some of these issues.

An example is in this paper:

http://www.ncbi.nlm.nih.gov/pmc/articles/PMC1664696/

I can ask the programmer there to dig up the R code although it shouldn't be hard to replicate.

alt text

ADD COMMENT
1
Entering edit mode
ADD REPLY
0
Entering edit mode

That is a really neat way to present sequence logos!

ADD REPLY
0
Entering edit mode

would be really interested to obtain the R code, did you have any luck with that?

ADD REPLY
0
Entering edit mode

I agree with Timtico, this is cool, and I would like the code as well. We'll try it out. But not quite what I was looking for.

ADD REPLY
0
Entering edit mode

i'll cook up some code that uses ggplot

ADD REPLY
0
Entering edit mode

thanks for that, i will try it out asap!

ADD REPLY
5
Entering edit mode
13.2 years ago
Timtico ▴ 330

Use R and the packages seqLogo and Biostrings.

I used to use them to make perfect vectorised sequencelogos in PDF format.

ADD COMMENT
2
Entering edit mode
10.6 years ago
by0 ▴ 110

Check out RWebLogo. It's an R wrapper for the WebLogo python library. It can be downloaded from CRAN: http://cran.r-project.org/web/packages/RWebLogo/index.html

and is hosted on github: https://github.com/omarwagih/RWebLogo

ADD COMMENT
1
Entering edit mode
13.2 years ago

We have tried WebLogo and SeqLogo, but ultimately wrote our own routines in R for maximal flexibility in terms of layout of plots and figures.

ADD COMMENT
1
Entering edit mode
13.2 years ago
puthier ▴ 10

I would suggest RSAT that can also be used as a stand-alone application and which implements lots of unix commands for position weight matrix analysis.

http://rsat.ulb.ac.be/

ADD COMMENT
0
Entering edit mode
2.9 years ago

Try an independent implementation from the motif set to the Sequence logo, or a direct offline application here: Make a Sequence Logo in your browser by using native Javascript

ADD COMMENT

Login before adding your answer.

Traffic: 1742 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6