Back to index

python-biopython  1.60
Functions | Variables
Bio.Data.IUPACData Namespace Reference

Functions

def _make_ranges
def _make_ambiguous_ranges

Variables

string protein_letters = "ACDEFGHIKLMNPQRSTVWY"
string extended_protein_letters = "ACDEFGHIKLMNPQRSTVWYBXZJUO"
string ambiguous_dna_letters = "GATCRYWSMKHBVDN"
string unambiguous_dna_letters = "GATC"
string ambiguous_rna_letters = "GAUCRYWSMKHBVDN"
string unambiguous_rna_letters = "GAUC"
string extended_dna_letters = "GATCBDSW"
dictionary ambiguous_dna_values
dictionary ambiguous_rna_values
dictionary ambiguous_dna_complement
dictionary ambiguous_rna_complement
dictionary unambiguous_dna_weights
tuple unambiguous_dna_weight_ranges = _make_ranges(unambiguous_dna_weights)
dictionary unambiguous_rna_weights
tuple unambiguous_rna_weight_ranges = _make_ranges(unambiguous_rna_weights)
dictionary protein_weights
dictionary extended_protein_values
tuple protein_weight_ranges = _make_ranges(protein_weights)
dictionary atom_weights

Function Documentation

def Bio.Data.IUPACData._make_ambiguous_ranges (   mydict,
  weight_table 
) [private]

Definition at line 139 of file IUPACData.py.

00139 
00140 def _make_ambiguous_ranges(mydict, weight_table):
00141     range_d = {}
00142     avg_d = {}
00143     for letter, values in mydict.iteritems():
00144         #Following line is a quick hack to skip undefined weights for U and O
00145         if len(values)==1 and values[0] not in weight_table : continue
00146         weights = map(weight_table.get, values)
00147         range_d[letter] = (min(weights), max(weights))
00148         total_w = 0.0
00149         for w in weights:
00150             total_w = total_w + w
00151         avg_d[letter] = total_w / len(weights)
00152     return range_d, avg_d
00153 
00154 ambiguous_dna_weight_ranges, avg_ambiguous_dna_weights = \
00155                _make_ambiguous_ranges(ambiguous_dna_values,
00156                                       unambiguous_dna_weights)
00157 
00158 ambiguous_rna_weight_ranges, avg_ambiguous_rna_weights = \
00159                _make_ambiguous_ranges(ambiguous_rna_values,
00160                                       unambiguous_rna_weights)

def Bio.Data.IUPACData._make_ranges (   mydict) [private]

Definition at line 116 of file IUPACData.py.

00116 
00117 def _make_ranges(mydict):
00118     d = {}
00119     for key, value in mydict.iteritems():
00120         d[key] = (value, value)
00121     return d
00122 
# From bioperl's SeqStats.pm

Variable Documentation

Initial value:
00001 {
00002     "A": "T",
00003     "C": "G",
00004     "G": "C",
00005     "T": "A",
00006     "M": "K",
00007     "R": "Y",
00008     "W": "W",
00009     "S": "S",
00010     "Y": "R",
00011     "K": "M",
00012     "V": "B",
00013     "H": "D",
00014     "D": "H",
00015     "B": "V",
00016     "X": "X",
00017     "N": "N",
00018     }

Definition at line 77 of file IUPACData.py.

string Bio.Data.IUPACData.ambiguous_dna_letters = "GATCRYWSMKHBVDN"

Definition at line 26 of file IUPACData.py.

Initial value:
00001 {
00002     "A": "A",
00003     "C": "C",
00004     "G": "G",
00005     "T": "T",
00006     "M": "AC",
00007     "R": "AG",
00008     "W": "AT",
00009     "S": "CG",
00010     "Y": "CT",
00011     "K": "GT",
00012     "V": "ACG",
00013     "H": "ACT",
00014     "D": "AGT",
00015     "B": "CGT",
00016     "X": "GATC",
00017     "N": "GATC",
00018     }

Definition at line 40 of file IUPACData.py.

Initial value:
00001 {
00002     "A": "U",
00003     "C": "G",
00004     "G": "C",
00005     "U": "A",
00006     "M": "K",
00007     "R": "Y",
00008     "W": "W",
00009     "S": "S",
00010     "Y": "R",
00011     "K": "M",
00012     "V": "B",
00013     "H": "D",
00014     "D": "H",
00015     "B": "V",
00016     "X": "X",
00017     "N": "N",
00018     }

Definition at line 96 of file IUPACData.py.

string Bio.Data.IUPACData.ambiguous_rna_letters = "GAUCRYWSMKHBVDN"

Definition at line 28 of file IUPACData.py.

Initial value:
00001 {
00002     "A": "A",
00003     "C": "C",
00004     "G": "G",
00005     "U": "U",
00006     "M": "AC",
00007     "R": "AG",
00008     "W": "AU",
00009     "S": "CG",
00010     "Y": "CU",
00011     "K": "GU",
00012     "V": "ACG",
00013     "H": "ACU",
00014     "D": "AGU",
00015     "B": "CGU",
00016     "X": "GAUC",
00017     "N": "GAUC",
00018     }

Definition at line 58 of file IUPACData.py.

Definition at line 226 of file IUPACData.py.

Definition at line 35 of file IUPACData.py.

string Bio.Data.IUPACData.extended_protein_letters = "ACDEFGHIKLMNPQRSTVWYBXZJUO"

Definition at line 4 of file IUPACData.py.

Initial value:
00001 {
00002     "A": "A",
00003     "B": "ND",
00004     "C": "C",
00005     "D": "D",
00006     "E": "E",
00007     "F": "F",
00008     "G": "G",
00009     "H": "H",
00010     "I": "I",
00011     "J": "IL",
00012     "K": "K",
00013     "L": "L",
00014     "M": "M",
00015     "N": "N",
00016     "O": "O",
00017     "P": "P",
00018     "Q": "Q",
00019     "R": "R",
00020     "S": "S",
00021     "T": "T",
00022     "U": "U",
00023     "V": "V",
00024     "W": "W",
00025     "X": "ACDEFGHIKLMNPQRSTVWY",
00026     #TODO - Include U and O in the possible values of X?
00027     #This could alter the extended_protein_weight_ranges ...
00028     "Y": "Y",
00029     "Z": "QE",
00030 }

Definition at line 186 of file IUPACData.py.

string Bio.Data.IUPACData.protein_letters = "ACDEFGHIKLMNPQRSTVWY"

Definition at line 3 of file IUPACData.py.

Definition at line 217 of file IUPACData.py.

Initial value:
00001 {
00002     "A": 89.09,
00003     "C": 121.16,
00004     "D": 133.10,
00005     "E": 147.13,
00006     "F": 165.19,
00007     "G": 75.07,
00008     "H": 155.16,
00009     "I": 131.18,
00010     "K": 146.19,
00011     "L": 131.18,
00012     "M": 149.21,
00013     "N": 132.12,
00014     #"O": 0.0, # Needs to be recorded!
00015     "P": 115.13,
00016     "Q": 146.15,
00017     "R": 174.20,
00018     "S": 105.09,
00019     "T": 119.12,
00020     #"U": 168.05, # To be confirmed
00021     "V": 117.15,
00022     "W": 204.23,
00023     "Y": 181.19
00024     }

Definition at line 161 of file IUPACData.py.

Definition at line 27 of file IUPACData.py.

Definition at line 129 of file IUPACData.py.

Initial value:
00001 {
00002     "A": 347.,
00003     "C": 323.,
00004     "G": 363.,
00005     "T": 322.,
00006     }

Definition at line 123 of file IUPACData.py.

Definition at line 29 of file IUPACData.py.

Definition at line 137 of file IUPACData.py.

Initial value:
00001 {
00002     "A": unambiguous_dna_weights["A"] + 16.,  # 16 for the oxygen
00003     "C": unambiguous_dna_weights["C"] + 16.,
00004     "G": unambiguous_dna_weights["G"] + 16.,
00005     "U": 340.,
00006 }

Definition at line 131 of file IUPACData.py.