[Biojava-l] textlogodrawer

Thomas Down td2@sanger.ac.uk
Thu, 3 Jan 2002 14:09:21 +0000


On Thu, Jan 03, 2002 at 02:37:30PM +0100, Bert Coessens wrote:
> Does anyone have an example of some code that can be used to draw
> motiflogo's from a distribution of information content per base? I'm
> trying to use the classes and interfaces from biojava.org, but can't
> figger out how I should program a working implementation.

Hi...

There's code in BioJava (since release 1.1) for drawing
`logo' representations of BioJava's Distribution objects,
in the package org.biojava.bio.gui, which I think should
do what you want (Note: you actually need to pass in a
probability distribution -- the information content gets
calculated for you).

If you download the BioJava source distribution (or check
a copy out from CVS), there's a small example program which
shows how these are used.  See demos/dist/TestDistribution.java

Let me know if you have any trouble with this,

    Thomas.