Re: "Python for Bioinformatics" available and in stock

2009-10-20 Thread Sebastian Bassi
On Mon, Oct 19, 2009 at 5:43 AM, Bearophile wrote: > A more pythonic code is: ... > Note the use of xrange and names_with_underscores. In Python names are > usually lower case and their parts are separated by underscores. Regarding underscore (and code notation in general) I wrote in the book (pa

Re: "Python for Bioinformatics" available and in stock

2009-10-19 Thread Bearophile
Sebastian Bassi, this is an piece from the #5: ProtSeq = raw_input("Protein sequence: ").upper() ProtDeg = {"A":4,"C":2,"D":2,"E":2,"F":2,"G":4,"H":2, "I":3,"K":2,"L":6,"M":1,"N":2,"P":4,"Q":2, "R":6,"S":6,"T":4,"V":4,"W":1,"Y":2} SegsValues = [] for aa in range(len(ProtSeq))