Fw: Re: Re: [Bioperl-l] Bio::Taxonomy::Tree

Qiang Tu qtu at sibs.ac.cn
Sat Apr 5 15:48:09 EST 2003


---Original Message---
From: Dan Kortschak<kortschak at fuckmicrosoft.com>
Subject: Re: Re: [Bioperl-l] Bio::Taxonomy::Tree
 
>Heikki and Qiang Tu,
>
>I'm afraid that all the low level stuff is not mine - Jason put all that
>together (I essentially just ripped his Node.pm for the Taxonomy modules
>and I don't think that I have made any sustantive changes to his code in
>the areas that deal with the basics of tree/node handling that are not
>dealt with by the interface except for removing methods/options that I
>thought were not intuitively appropriate for species taxonomic trees -
>though maybe I'm wrong). It might be worth asking Jason.
>
>Please forward this to the list as I am longer subscribed.
>
>cheers and good luck
>Dan
>
>On 4 Apr 2003, Heikki Lehvaslaiho wrote:
>
>>
>> I am glad that you got code working but in general it would be better to
>> understand where the two enclosed parenthesis pairs arise and fix that.
>> Maybe Dan Kortschak who wrote the taxonomy modules can help.
>>
>> 	-Heikki
>>
>> On Sat, 2003-04-05 at 00:05, Qiang TU wrote:
>> > Hi Heikki,
>> >
>> > Yes, those strange characters may cause trouble. Besides, another problem
>> > is single branch at several levels may cause many brackets, e.g. (((a,b)),c);
>> > and these continuous brackets are illegal for the draw tree softwares. So, I
>> > add a condition in the sub _write_tree_Helper in newick.pm to prevent
>> > outputting these extra nodes:
>> >
>> > 209,211c209,213
>> > <       $data[0] = "(" . $data[0];
>> > <       $data[-1] .= ")";
>> > <       $data[-1] .= ":". $node->branch_length if( $node->branch_length);
>> > ---
>> > >       if (scalar($node->each_Descendent()) > 1) {
>> > >           $data[0] = "(" . $data[0];
>> > >           $data[-1] .= ")";
>> > >           $data[-1] .= ":". $node->branch_length if( $node->branch_length);
>> > >       }
>> >
>> >
>> > Now it works for my problem. But I am not sure if it is a right way to draw
>> > trees. Or maybe we can add an option to let user to choice?
>> >
>> > Thanks.
>> >
>> > Qiang Tu
>> >
>> > BTW: I am using bioperl 1.2.
>> >
>> > ---Original Message---
>> > From: Heikki Lehvaslaiho<heikki at ebi.ac.uk>
>> > Subject: Re: [Bioperl-l] Bio::Taxonomy::Tree
>> >
>> > >Quing Tu,
>> > >
>> > >I found this from
>> > >http://evolution.genetics.washington.edu/phylip/newicktree.html :
>> > >
>> > >"A name can be any string of printable characters except blanks,
>> > > colons, semicolons, parentheses, and square brackets.
>> > >
>> > > Because you may want to include a blank in a name, it is assumed that
>> > > an underscore character ("_") stands for a blank; any of these in a
>> > > name will be converted to a blank when it is read in."
>> > >
>> > >
>> > >I am adding the conversion into Bio::Tree::Node::id.
>> > >The method will print a warning, too, if $node->verbose >=0
>> > >
>> > >Check the CVS after a while.
>> > >
>> > >	-Heikki
>> > >
>> > >On Thu, 2003-04-03 at 17:02, Heikki Lehvaslaiho wrote:
>> > >> Your tree looks OK. I did not try to it with any program, so this is
>> > >> just a wild guess, but try removing spaces from the tree and try again.
>> > >>
>> > >> 	-Heikki
>> > >>
>> > >>
>> > >>
>> > >> On Thu, 2003-04-03 at 14:02, Qiang Tu wrote:
>> > >> > Hello all,
>> > >> >
>> > >> > I want to build a taxonomy tree of the complete genomes. In the
>> > >> > program I built a Bio::Taxonomy::Taxon object at first, then use
>> > >> > 'set_root_node' method to built a Bio::Taxonomy::Tree objxect by
>> > >> > the taxon, then write the tree to a file by Bio::TreeIO object.
>> > >> > The 'tabtree' method works, but the output files of 'newick' and
>> > >> > 'nhx' methods can not be opened by other draw-tree software, such
>> > >> > as treeview. The error message is: Extra pair of parentheses
>> > >> > "()". The tree file is attached.
>> > >> >
>> > >> > Has anyone ever made such a taxonomy tree? Could you give me some
>> > >> > samples so that I can find out the solution of my problem?
>> > >> > Thanks.
>> > >> >
>> > >> > Qiang Tu
>> > >> > Institute of Biochemistry and Cell Biology
>> > >> > Chinese Academy of Sciences
>> > >> >
>> > >> > ______________________________________________________________________
>> > >> >
>> > >> > _______________________________________________
>> > >> > Bioperl-l mailing list
>> > >> > Bioperl-l at bioperl.org
>> > >> > http://bioperl.org/mailman/listinfo/bioperl-l
>> > >--
>> > >______ _/      _/_____________________________________________________
>> > >      _/      _/                      http://www.ebi.ac.uk/mutations/
>> > >     _/  _/  _/  Heikki Lehvaslaiho          heikki at ebi.ac.uk
>> > >    _/_/_/_/_/  EMBL Outstation, European Bioinformatics Institute
>> > >   _/  _/  _/  Wellcome Trust Genome Campus, Hinxton
>> > >  _/  _/  _/  Cambs. CB10 1SD, United Kingdom
>> > >     _/      Phone: +44 (0)1223 494 644   FAX: +44 (0)1223 494 468
>> > >___ _/_/_/_/_/________________________________________________________
>> > >
>> > >
>> >
>> >
>> > ---End of Message---
>> >
>> >
>> > Qiang Tu
>> > Institute of Biochemistry and Cell Biology
>> > Chinese Academy of Sciences
>> > Email: tuqiang at mail.shcnc.ac.cn, tuqiang_cn at yahoo.com
>> >
>>
>
>-- 
>_____________________________________________________________   .`.`o
>                                                         o| ,\__ `./`r
>  Dan Kortschak     kortschak at fuckmicrosoft.com       <\/    \_O> O
>                                                          "|`...'.\
>  Is a citizen subject to the laws of a criminal state?    `      :\
>                                                                  : \
>
>  See headers for PGP public key.
>
>  By replying to this email you implicitly accept that your response
>  may be forwarded to other recipients.
>

 
---End of Message---

 
Qiang Tu
Institute of Biochemistry and Cell Biology
Chinese Academy of Sciences
Email: tuqiang at mail.shcnc.ac.cn, tuqiang_cn at yahoo.com



More information about the Bioperl-l mailing list