[Biopython-dev] Nexus parser
Frank Kauff
fkauff at duke.edu
Tue Feb 15 18:00:37 EST 2005
On Tue, 2005-02-15 at 16:58 -0500, Frank Kauff wrote:
> On Tue, 2005-02-15 at 21:37 +0000, Michael Hoffman wrote:
> > On Tue, 15 Feb 2005, Iddo Friedberg wrote:
> >
> > > Good News: Frank Kauff & Cymon Cox has contributed a Nexus parser to
> > > Biopython, for our next release. It's a mighty useful and nifty package if
> > > you are into trees (the phylogenetic ones, not the ones in the forest).
> >
> > Yay!
> >
> > > All current Linux distros use a <=2.3 version, and 2.3 does not have
> > > Sets.
> >
> > Actually, it does:
> >
> > $ python2.3
> > Python 2.3.4 (#1, Feb 2 2005, 12:11:53)
> > [GCC 3.4.2 20041017 (Red Hat 3.4.2-6.fc3)] on linux2
> > Type "help", "copyright", "credits" or "license" for more information.
> > >>> import sets
> > >>> sets.Set("biopython")
> > Set(['b', 'i', 'h', 'o', 'n', 'p', 't', 'y'])
> >
> > It just doesn't have the built-in sets of Python 2.4:
> >
>
> Out of the top of my head - I think built-in set syntax is the only
> python2.4 feature I use in Nexus.py (but I'd have to check). If we would
> opt for 2.3 relase, a simple search replace of set with sets.Set and an
> import sets should do the trick, right?
>
So I did this (by hand, not with a global replace...) and it passes all
tests with python2.3.4. Could have thought earlier of this issue, sorry
for the confusion.
Iddo, I'll send you the new module in a minute.
F.
> Frank
>
> > $ python2.4
> > Python 2.4 (#1, Nov 30 2004, 11:25:14)
> > [GCC 3.4.2 20041017 (Red Hat 3.4.2-6.fc3)] on linux2
> > Type "help", "copyright", "credits" or "license" for more information.
> > >>> set("biopython")
> > set(['b', 'i', 'h', 'o', 'n', 'p', 't', 'y'])
> >
> > That said, my vote is to include the module, even in its requiring-2.4
> > version.
>
>
--
Frank Kauff
Dept. of Biology
Duke University
Box 90338
Durham, NC 27708
USA
Phone 919-660-7382
Fax 919-660-7293
Web http://www.lutzonilab.net/member/frankkauff.shtml
More information about the Biopython-dev
mailing list