Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

bio::graphics(3pm) [debian man page]

Bio::Graphics(3pm)					User Contributed Perl Documentation					Bio::Graphics(3pm)

NAME
Bio::Graphics - Generate GD images of Bio::Seq objects SYNOPSIS
# This script generates a PNG picture of a 10K region containing a # set of red features and a set of blue features. Call it like this: # red_and_blue.pl > redblue.png # you can now view the picture with your favorite image application # This script parses a GenBank or EMBL file named on the command # line and produces a PNG rendering of it. Call it like this: # render.pl my_file.embl | display - use strict; use Bio::Graphics; use Bio::SeqFeature::Generic; use Bio::SeqIO; my $file = shift or die "provide a sequence file as the argument"; my $io = Bio::SeqIO->new(-file=>$file) or die "could not create Bio::SeqIO"; my $seq = $io->next_seq or die "could not find a sequence in the file"; my @features = $seq->all_SeqFeatures; # sort features by their primary tags my %sorted_features; for my $f (@features) { my $tag = $f->primary_tag; push @{$sorted_features{$tag}},$f; } my $wholeseq = Bio::SeqFeature::Generic->new(-start=>1,-end=>$seq->length); my $panel = Bio::Graphics::Panel->new( -length => $seq->length, -key_style => 'between', -width => 800, -pad_left => 10, -pad_right => 10, ); $panel->add_track($wholeseq, -glyph => 'arrow', -bump => 0, -double=>1, -tick => 2); $panel->add_track($wholeseq, -glyph => 'generic', -bgcolor => 'blue', -label => 1, ); # general case my @colors = qw(cyan orange blue purple green chartreuse magenta yellow aqua); my $idx = 0; for my $tag (sort keys %sorted_features) { my $features = $sorted_features{$tag}; $panel->add_track($features, -glyph => 'generic', -bgcolor => $colors[$idx++ % @colors], -fgcolor => 'black', -font2color => 'red', -key => "${tag}s", -bump => +1, -height => 8, -label => 1, -description => 1, ); } print $panel->png; exit 0; DESCRIPTION
Please see Bio::Graphics::Panel for the full interface. Also try the script glyph_help.pl for quick help on glyphs and their options. SEE ALSO
Bio::Graphics::Panel, Bio::Graphics::Glyph, Bio::SeqI, Bio::SeqFeatureI, Bio::Das, Bio::DB::GFF::Feature, Ace::Sequence, GD glyph_help.pl FEEDBACK
Mailing Lists User feedback is an integral part of the evolution of this and other Bioperl modules. Send your comments and suggestions preferably to the Bioperl mailing list. Your participation is much appreciated. bioperl-l@bioperl.org - General discussion http://bioperl.org/wiki/Mailing_lists - About the mailing lists Reporting Bugs Report bugs to the Bioperl bug tracking system to help us keep track of the bugs and their resolution. Bug reports can be submitted via the web: http://bugzilla.open-bio.org/ AUTHOR
Lincoln Stein <lstein@cshl.org>. Copyright (c) 2001 Cold Spring Harbor Laboratory This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself. See DISCLAIMER.txt for disclaimers of warranty. perl v5.14.2 2012-02-20 Bio::Graphics(3pm)

Check Out this Related Man Page

Bio::Graphics::Glyph::text_in_box(3pm)			User Contributed Perl Documentation		    Bio::Graphics::Glyph::text_in_box(3pm)

NAME
Bio::Graphics::Glyph::text_in_box - The "text in box" glyph SYNOPSIS
See L<Bio::Graphics::Panel> and L<Bio::Graphics::Glyph>. DESCRIPTION
This glyph draws the specified text in a rectangular box. OPTIONS In addition to the common options, the following glyph-specific options are recognized: Option Description Default ------ ----------- ------- -text The text to draw in the box 3' -text_pad The number of pixels to offset 3 the box -text_bgcolor none The background color of the box BUGS
Please report them. SEE ALSO
Bio::Graphics::Panel, Bio::Graphics::Glyph, Bio::Graphics::Glyph::arrow, Bio::Graphics::Glyph::cds, Bio::Graphics::Glyph::crossbox, Bio::Graphics::Glyph::diamond, Bio::Graphics::Glyph::dna, Bio::Graphics::Glyph::dot, Bio::Graphics::Glyph::ellipse, Bio::Graphics::Glyph::extending_arrow, Bio::Graphics::Glyph::generic, Bio::Graphics::Glyph::graded_segments, Bio::Graphics::Glyph::heterogeneous_segments, Bio::Graphics::Glyph::line, Bio::Graphics::Glyph::pinsertion, Bio::Graphics::Glyph::primers, Bio::Graphics::Glyph::rndrect, Bio::Graphics::Glyph::segments, Bio::Graphics::Glyph::ruler_arrow, Bio::Graphics::Glyph::toomany, Bio::Graphics::Glyph::transcript, Bio::Graphics::Glyph::transcript2, Bio::Graphics::Glyph::translation, Bio::Graphics::Glyph::triangle, Bio::DB::GFF, Bio::SeqI, Bio::SeqFeatureI, Bio::Das, GD AUTHOR
Vsevolod (Simon) Ilyushchenko <simonf@cshl.edu>. Copyright (c) 2004 Cold Spring Harbor Laboratory This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself. See DISCLAIMER.txt for disclaimers of warranty. perl v5.14.2 2012-02-20 Bio::Graphics::Glyph::text_in_box(3pm)
Man Page