hexsha
stringlengths
40
40
repo
stringlengths
7
114
path
stringlengths
4
124
license
listlengths
1
9
language
stringclasses
1 value
identifier
stringlengths
1
71
return_type
stringlengths
1
749
⌀
original_string
stringlengths
76
22.7k
original_docstring
stringlengths
16
7.61k
docstring
stringlengths
16
2.47k
docstring_tokens
listlengths
6
477
code
stringlengths
14
10.2k
code_tokens
listlengths
6
996
short_docstring
stringlengths
2
644
short_docstring_tokens
listlengths
1
116
comment
listlengths
1
89
parameters
listlengths
0
64
docstring_params
dict
535f6fccc44bf532f1700aba30493c21b723a489
shambo001/peat
PEATDB/DNAtool/DNAtool.py
[ "MIT" ]
Python
load_preferences
<not_specific>
def load_preferences(self): """Loads the sequence display settings from prefs file, if present""" print 'Loading current DNAtool preferences' self.preferences = Preferences('DNAtool',{'canvas_height':600}) for key in self.defaultprefs: if key in self.preferences.prefs: ...
Loads the sequence display settings from prefs file, if present
Loads the sequence display settings from prefs file, if present
[ "Loads", "the", "sequence", "display", "settings", "from", "prefs", "file", "if", "present" ]
def load_preferences(self): print 'Loading current DNAtool preferences' self.preferences = Preferences('DNAtool',{'canvas_height':600}) for key in self.defaultprefs: if key in self.preferences.prefs: self.__dict__[key].set(self.preferences.get(key)) else: ...
[ "def", "load_preferences", "(", "self", ")", ":", "print", "'Loading current DNAtool preferences'", "self", ".", "preferences", "=", "Preferences", "(", "'DNAtool'", ",", "{", "'canvas_height'", ":", "600", "}", ")", "for", "key", "in", "self", ".", "defaultpref...
Loads the sequence display settings from prefs file, if present
[ "Loads", "the", "sequence", "display", "settings", "from", "prefs", "file", "if", "present" ]
[ "\"\"\"Loads the sequence display settings from prefs file, if present\"\"\"" ]
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
535f6fccc44bf532f1700aba30493c21b723a489
shambo001/peat
PEATDB/DNAtool/DNAtool.py
[ "MIT" ]
Python
update_window_formatting
<not_specific>
def update_window_formatting(self): """Do this only when display setup changes are applied. Ensures all objects, including applied primers are updated with the new formatting.""" self.update_sequence_window() if self.pDB_open: self.pDB_open.refresh_primer() if self....
Do this only when display setup changes are applied. Ensures all objects, including applied primers are updated with the new formatting.
Do this only when display setup changes are applied. Ensures all objects, including applied primers are updated with the new formatting.
[ "Do", "this", "only", "when", "display", "setup", "changes", "are", "applied", ".", "Ensures", "all", "objects", "including", "applied", "primers", "are", "updated", "with", "the", "new", "formatting", "." ]
def update_window_formatting(self): self.update_sequence_window() if self.pDB_open: self.pDB_open.refresh_primer() if self.show_comp_sequence.get==1: self.sequ_win.refresh_DNAseq() return
[ "def", "update_window_formatting", "(", "self", ")", ":", "self", ".", "update_sequence_window", "(", ")", "if", "self", ".", "pDB_open", ":", "self", ".", "pDB_open", ".", "refresh_primer", "(", ")", "if", "self", ".", "show_comp_sequence", ".", "get", "=="...
Do this only when display setup changes are applied.
[ "Do", "this", "only", "when", "display", "setup", "changes", "are", "applied", "." ]
[ "\"\"\"Do this only when display setup changes are applied. Ensures all objects, including\n applied primers are updated with the new formatting.\"\"\"" ]
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
535f6fccc44bf532f1700aba30493c21b723a489
shambo001/peat
PEATDB/DNAtool/DNAtool.py
[ "MIT" ]
Python
overview_on_off
<not_specific>
def overview_on_off(self): """Turn the over view window on and off""" if self.overview_win: self.overview_button.deselect() self.overview_win.destroy() self.overview_win=None else: self.overview_button.select() if not self.data.has_key...
Turn the over view window on and off
Turn the over view window on and off
[ "Turn", "the", "over", "view", "window", "on", "and", "off" ]
def overview_on_off(self): if self.overview_win: self.overview_button.deselect() self.overview_win.destroy() self.overview_win=None else: self.overview_button.select() if not self.data.has_key('AA_seqs1'): self.warning('No DNA s...
[ "def", "overview_on_off", "(", "self", ")", ":", "if", "self", ".", "overview_win", ":", "self", ".", "overview_button", ".", "deselect", "(", ")", "self", ".", "overview_win", ".", "destroy", "(", ")", "self", ".", "overview_win", "=", "None", "else", "...
Turn the over view window on and off
[ "Turn", "the", "over", "view", "window", "on", "and", "off" ]
[ "\"\"\"Turn the over view window on and off\"\"\"", "# Open Canvas and draw lines", "#", "# Draw", "#" ]
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
535f6fccc44bf532f1700aba30493c21b723a489
shambo001/peat
PEATDB/DNAtool/DNAtool.py
[ "MIT" ]
Python
compare_DNA_seq
<not_specific>
def compare_DNA_seq(self): """load and display a sequence from a file to compare to the currently displayed sequence""" import tkMessageBox if self.data['DNAseq']=='' or not self.data['DNAseq']: tkMessageBox.showwarning( "Compare DNA Sequence", "L...
load and display a sequence from a file to compare to the currently displayed sequence
load and display a sequence from a file to compare to the currently displayed sequence
[ "load", "and", "display", "a", "sequence", "from", "a", "file", "to", "compare", "to", "the", "currently", "displayed", "sequence" ]
def compare_DNA_seq(self): import tkMessageBox if self.data['DNAseq']=='' or not self.data['DNAseq']: tkMessageBox.showwarning( "Compare DNA Sequence", "Load a DNA sequence first\nUse the Browse Button" ) return else: self.s...
[ "def", "compare_DNA_seq", "(", "self", ")", ":", "import", "tkMessageBox", "if", "self", ".", "data", "[", "'DNAseq'", "]", "==", "''", "or", "not", "self", ".", "data", "[", "'DNAseq'", "]", ":", "tkMessageBox", ".", "showwarning", "(", "\"Compare DNA Seq...
load and display a sequence from a file to compare to the currently displayed sequence
[ "load", "and", "display", "a", "sequence", "from", "a", "file", "to", "compare", "to", "the", "currently", "displayed", "sequence" ]
[ "\"\"\"load and display a sequence from a file to compare to the currently\n displayed sequence\"\"\"" ]
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
535f6fccc44bf532f1700aba30493c21b723a489
shambo001/peat
PEATDB/DNAtool/DNAtool.py
[ "MIT" ]
Python
compare_multiple_seqs
<not_specific>
def compare_multiple_seqs(self): """load and display many sequences in a set of files or zip file""" import tkMessageBox if self.data['DNAseq']=='' or not self.data['DNAseq']: tkMessageBox.showwarning( "Compare DNA Sequence", "Load a DNA sequence first\nUse th...
load and display many sequences in a set of files or zip file
load and display many sequences in a set of files or zip file
[ "load", "and", "display", "many", "sequences", "in", "a", "set", "of", "files", "or", "zip", "file" ]
def compare_multiple_seqs(self): import tkMessageBox if self.data['DNAseq']=='' or not self.data['DNAseq']: tkMessageBox.showwarning( "Compare DNA Sequence", "Load a DNA sequence first\nUse the Browse Button" ) return else: ...
[ "def", "compare_multiple_seqs", "(", "self", ")", ":", "import", "tkMessageBox", "if", "self", ".", "data", "[", "'DNAseq'", "]", "==", "''", "or", "not", "self", ".", "data", "[", "'DNAseq'", "]", ":", "tkMessageBox", ".", "showwarning", "(", "\"Compare D...
load and display many sequences in a set of files or zip file
[ "load", "and", "display", "many", "sequences", "in", "a", "set", "of", "files", "or", "zip", "file" ]
[ "\"\"\"load and display many sequences in a set of files or zip file\"\"\"", "#print self,'inDNAtool'", "#self.wait_window(self.sequ_win.si_window)" ]
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
535f6fccc44bf532f1700aba30493c21b723a489
shambo001/peat
PEATDB/DNAtool/DNAtool.py
[ "MIT" ]
Python
clear_comp_seqs
<not_specific>
def clear_comp_seqs(self, event=None): """switch off display of extra comparison sequences""" self.show_comp_sequence.set(0) print 'clearing comp seq' self.seqframe.delete('comparison_seq') self.seqframe.delete('strip') self.max_seq_level=0 self.update_sequence_w...
switch off display of extra comparison sequences
switch off display of extra comparison sequences
[ "switch", "off", "display", "of", "extra", "comparison", "sequences" ]
def clear_comp_seqs(self, event=None): self.show_comp_sequence.set(0) print 'clearing comp seq' self.seqframe.delete('comparison_seq') self.seqframe.delete('strip') self.max_seq_level=0 self.update_sequence_window() if self.pDB_open: self.pDB_open.refr...
[ "def", "clear_comp_seqs", "(", "self", ",", "event", "=", "None", ")", ":", "self", ".", "show_comp_sequence", ".", "set", "(", "0", ")", "print", "'clearing comp seq'", "self", ".", "seqframe", ".", "delete", "(", "'comparison_seq'", ")", "self", ".", "se...
switch off display of extra comparison sequences
[ "switch", "off", "display", "of", "extra", "comparison", "sequences" ]
[ "\"\"\"switch off display of extra comparison sequences\"\"\"" ]
[ { "param": "self", "type": null }, { "param": "event", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "event", "type": null, "docstring": null, "docstring_tokens": ...
b3736aea4b37ecf8a47ec3361bdb188dcfb75f73
shambo001/peat
Protool/structure.py
[ "MIT" ]
Python
resnum
<not_specific>
def resnum(self,uniqueid): """Given a uniqueid this function returns the residue number""" import string if len(string.split(uniqueid,','))>1: return string.split(uniqueid,':')[0]+':'+string.zfill(string.split(uniqueid,':')[1],self.length_of_residue_numbers)+','+string.split(uniqueid...
Given a uniqueid this function returns the residue number
Given a uniqueid this function returns the residue number
[ "Given", "a", "uniqueid", "this", "function", "returns", "the", "residue", "number" ]
def resnum(self,uniqueid): import string if len(string.split(uniqueid,','))>1: return string.split(uniqueid,':')[0]+':'+string.zfill(string.split(uniqueid,':')[1],self.length_of_residue_numbers)+','+string.split(uniqueid,',')[1] else: return string.split(uniqueid,':')[0]+...
[ "def", "resnum", "(", "self", ",", "uniqueid", ")", ":", "import", "string", "if", "len", "(", "string", ".", "split", "(", "uniqueid", ",", "','", ")", ")", ">", "1", ":", "return", "string", ".", "split", "(", "uniqueid", ",", "':'", ")", "[", ...
Given a uniqueid this function returns the residue number
[ "Given", "a", "uniqueid", "this", "function", "returns", "the", "residue", "number" ]
[ "\"\"\"Given a uniqueid this function returns the residue number\"\"\"" ]
[ { "param": "self", "type": null }, { "param": "uniqueid", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "uniqueid", "type": null, "docstring": null, "docstring_tokens...
b3736aea4b37ecf8a47ec3361bdb188dcfb75f73
shambo001/peat
Protool/structure.py
[ "MIT" ]
Python
resname
<not_specific>
def resname(self,uniqueid): """ Given an uniqueid or a residue number, this function returns the residue name""" import string if self.atoms.has_key(uniqueid): return self.atoms[uniqueid]['RESNAME'] elif self.residues.has_key(uniqueid): # # Get the fir...
Given an uniqueid or a residue number, this function returns the residue name
Given an uniqueid or a residue number, this function returns the residue name
[ "Given", "an", "uniqueid", "or", "a", "residue", "number", "this", "function", "returns", "the", "residue", "name" ]
def resname(self,uniqueid): import string if self.atoms.has_key(uniqueid): return self.atoms[uniqueid]['RESNAME'] elif self.residues.has_key(uniqueid): Get the first atom of the residue and return the resname there atomname=self.residues[uniqueid][0] ...
[ "def", "resname", "(", "self", ",", "uniqueid", ")", ":", "import", "string", "if", "self", ".", "atoms", ".", "has_key", "(", "uniqueid", ")", ":", "return", "self", ".", "atoms", "[", "uniqueid", "]", "[", "'RESNAME'", "]", "elif", "self", ".", "re...
Given an uniqueid or a residue number, this function returns the residue name
[ "Given", "an", "uniqueid", "or", "a", "residue", "number", "this", "function", "returns", "the", "residue", "name" ]
[ "\"\"\" Given an uniqueid or a residue number, this function returns the residue name\"\"\"", "#", "# Get the first atom of the residue and return the resname there", "#", "#", "# Check for non-existing atom, but existing residue", "#" ]
[ { "param": "self", "type": null }, { "param": "uniqueid", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "uniqueid", "type": null, "docstring": null, "docstring_tokens...
b3736aea4b37ecf8a47ec3361bdb188dcfb75f73
shambo001/peat
Protool/structure.py
[ "MIT" ]
Python
NextResidue
<not_specific>
def NextResidue(self,resid,checkforbound=1): """ # This function returns the residue one after resid in the sequence in the same molecule # This function only works for amino acids """ if not self.isaa(resid): raise NotAnAminoAcidError('%s %s' %(resid,self.resname(res...
# This function returns the residue one after resid in the sequence in the same molecule # This function only works for amino acids
This function returns the residue one after resid in the sequence in the same molecule This function only works for amino acids
[ "This", "function", "returns", "the", "residue", "one", "after", "resid", "in", "the", "sequence", "in", "the", "same", "molecule", "This", "function", "only", "works", "for", "amino", "acids" ]
def NextResidue(self,resid,checkforbound=1): if not self.isaa(resid): raise NotAnAminoAcidError('%s %s' %(resid,self.resname(resid))) Make sure we get rid of all ',ALT' records in the name when skipping residues resid=resid.replace(',ALT','') residues=self.residues.keys() ...
[ "def", "NextResidue", "(", "self", ",", "resid", ",", "checkforbound", "=", "1", ")", ":", "if", "not", "self", ".", "isaa", "(", "resid", ")", ":", "raise", "NotAnAminoAcidError", "(", "'%s %s'", "%", "(", "resid", ",", "self", ".", "resname", "(", ...
This function returns the residue one after resid in the sequence in the same molecule This function only works for amino acids
[ "This", "function", "returns", "the", "residue", "one", "after", "resid", "in", "the", "sequence", "in", "the", "same", "molecule", "This", "function", "only", "works", "for", "amino", "acids" ]
[ "\"\"\"\n # This function returns the residue one after resid in the sequence in the same molecule\n # This function only works for amino acids\n \"\"\"", "#", "# Make sure we get rid of all ',ALT' records in the name when skipping residues", "#", "#", "# We have to look beyond the ne...
[ { "param": "self", "type": null }, { "param": "resid", "type": null }, { "param": "checkforbound", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "resid", "type": null, "docstring": null, "docstring_tokens": ...
b3736aea4b37ecf8a47ec3361bdb188dcfb75f73
shambo001/peat
Protool/structure.py
[ "MIT" ]
Python
GetPosition
<not_specific>
def GetPosition(self,uniqueid): """ # This function loads the X, Y and Z coordinates of the atom # in an Numeric Python vector """ if not self.atoms.has_key(uniqueid): raise AtomNotFoundError,uniqueid if not self.atoms[uniqueid].has_key('X') or not self.atoms[...
# This function loads the X, Y and Z coordinates of the atom # in an Numeric Python vector
This function loads the X, Y and Z coordinates of the atom in an Numeric Python vector
[ "This", "function", "loads", "the", "X", "Y", "and", "Z", "coordinates", "of", "the", "atom", "in", "an", "Numeric", "Python", "vector" ]
def GetPosition(self,uniqueid): if not self.atoms.has_key(uniqueid): raise AtomNotFoundError,uniqueid if not self.atoms[uniqueid].has_key('X') or not self.atoms[uniqueid].has_key('Y') or not self.atoms[uniqueid].has_key('Z'): print self.atoms[uniqueid] raise Incomplet...
[ "def", "GetPosition", "(", "self", ",", "uniqueid", ")", ":", "if", "not", "self", ".", "atoms", ".", "has_key", "(", "uniqueid", ")", ":", "raise", "AtomNotFoundError", ",", "uniqueid", "if", "not", "self", ".", "atoms", "[", "uniqueid", "]", ".", "ha...
This function loads the X, Y and Z coordinates of the atom in an Numeric Python vector
[ "This", "function", "loads", "the", "X", "Y", "and", "Z", "coordinates", "of", "the", "atom", "in", "an", "Numeric", "Python", "vector" ]
[ "\"\"\"\n # This function loads the X, Y and Z coordinates of the atom\n # in an Numeric Python vector\n \"\"\"" ]
[ { "param": "self", "type": null }, { "param": "uniqueid", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "uniqueid", "type": null, "docstring": null, "docstring_tokens...
b3736aea4b37ecf8a47ec3361bdb188dcfb75f73
shambo001/peat
Protool/structure.py
[ "MIT" ]
Python
SetPosition
<not_specific>
def SetPosition(self,uniqueid,coords): """Set the coordinates of this atom""" if not self.atoms.has_key(uniqueid): raise AtomNotFoundError,uniqueid self.atoms[uniqueid]['X']=coords[0] self.atoms[uniqueid]['Y']=coords[1] self.atoms[uniqueid]['Z']=coords[2] ret...
Set the coordinates of this atom
Set the coordinates of this atom
[ "Set", "the", "coordinates", "of", "this", "atom" ]
def SetPosition(self,uniqueid,coords): if not self.atoms.has_key(uniqueid): raise AtomNotFoundError,uniqueid self.atoms[uniqueid]['X']=coords[0] self.atoms[uniqueid]['Y']=coords[1] self.atoms[uniqueid]['Z']=coords[2] return
[ "def", "SetPosition", "(", "self", ",", "uniqueid", ",", "coords", ")", ":", "if", "not", "self", ".", "atoms", ".", "has_key", "(", "uniqueid", ")", ":", "raise", "AtomNotFoundError", ",", "uniqueid", "self", ".", "atoms", "[", "uniqueid", "]", "[", "...
Set the coordinates of this atom
[ "Set", "the", "coordinates", "of", "this", "atom" ]
[ "\"\"\"Set the coordinates of this atom\"\"\"" ]
[ { "param": "self", "type": null }, { "param": "uniqueid", "type": null }, { "param": "coords", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "uniqueid", "type": null, "docstring": null, "docstring_tokens...
b3736aea4b37ecf8a47ec3361bdb188dcfb75f73
shambo001/peat
Protool/structure.py
[ "MIT" ]
Python
add_atom
<not_specific>
def add_atom(self,uniqueid, atomnumber=0,atomname='X', chainid='X',residuename='DUM',residuenumber='000', xcoord=0.0,ycoord=0.0,zcoord=0.0,update=1,BFACTOR=None,OCCUPANCY=None,CHARGE=None,RADIUS=None,tag=None,accept_duplicate=False): """Add an atom to the array...
Add an atom to the arrays
Add an atom to the arrays
[ "Add", "an", "atom", "to", "the", "arrays" ]
def add_atom(self,uniqueid, atomnumber=0,atomname='X', chainid='X',residuename='DUM',residuenumber='000', xcoord=0.0,ycoord=0.0,zcoord=0.0,update=1,BFACTOR=None,OCCUPANCY=None,CHARGE=None,RADIUS=None,tag=None,accept_duplicate=False): Correct for duplicate atom...
[ "def", "add_atom", "(", "self", ",", "uniqueid", ",", "atomnumber", "=", "0", ",", "atomname", "=", "'X'", ",", "chainid", "=", "'X'", ",", "residuename", "=", "'DUM'", ",", "residuenumber", "=", "'000'", ",", "xcoord", "=", "0.0", ",", "ycoord", "=", ...
Add an atom to the arrays
[ "Add", "an", "atom", "to", "the", "arrays" ]
[ "\"\"\"Add an atom to the arrays\"\"\"", "#", "# Correct for duplicate atom names", "#", "#", "# Add the atom", "#" ]
[ { "param": "self", "type": null }, { "param": "uniqueid", "type": null }, { "param": "atomnumber", "type": null }, { "param": "atomname", "type": null }, { "param": "chainid", "type": null }, { "param": "residuename", "type": null }, { "par...
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "uniqueid", "type": null, "docstring": null, "docstring_tokens...
b3736aea4b37ecf8a47ec3361bdb188dcfb75f73
shambo001/peat
Protool/structure.py
[ "MIT" ]
Python
remove_residue
<not_specific>
def remove_residue(self,unique_identifier,update=True): """Remove a residue. This includes deleted all atoms in the residue""" if not self.residues.has_key(unique_identifier): raise ResidueNotFoundError(unique_identifier) for atom in self.residues[unique_identifier]: self...
Remove a residue. This includes deleted all atoms in the residue
Remove a residue. This includes deleted all atoms in the residue
[ "Remove", "a", "residue", ".", "This", "includes", "deleted", "all", "atoms", "in", "the", "residue" ]
def remove_residue(self,unique_identifier,update=True): if not self.residues.has_key(unique_identifier): raise ResidueNotFoundError(unique_identifier) for atom in self.residues[unique_identifier]: self.remove_atom(atom,update=False) if update: self.Update() ...
[ "def", "remove_residue", "(", "self", ",", "unique_identifier", ",", "update", "=", "True", ")", ":", "if", "not", "self", ".", "residues", ".", "has_key", "(", "unique_identifier", ")", ":", "raise", "ResidueNotFoundError", "(", "unique_identifier", ")", "for...
Remove a residue.
[ "Remove", "a", "residue", "." ]
[ "\"\"\"Remove a residue. This includes deleted all atoms in the residue\"\"\"" ]
[ { "param": "self", "type": null }, { "param": "unique_identifier", "type": null }, { "param": "update", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "unique_identifier", "type": null, "docstring": null, "docstri...
b3736aea4b37ecf8a47ec3361bdb188dcfb75f73
shambo001/peat
Protool/structure.py
[ "MIT" ]
Python
Remove_All_NonAminoAcids
<not_specific>
def Remove_All_NonAminoAcids(self): """Remove all non amino acid residues""" for residue in self.residues.keys(): if not self.isaa(residue): for atom in self.residues[residue]: del self.atoms[atom] self.Update() return
Remove all non amino acid residues
Remove all non amino acid residues
[ "Remove", "all", "non", "amino", "acid", "residues" ]
def Remove_All_NonAminoAcids(self): for residue in self.residues.keys(): if not self.isaa(residue): for atom in self.residues[residue]: del self.atoms[atom] self.Update() return
[ "def", "Remove_All_NonAminoAcids", "(", "self", ")", ":", "for", "residue", "in", "self", ".", "residues", ".", "keys", "(", ")", ":", "if", "not", "self", ".", "isaa", "(", "residue", ")", ":", "for", "atom", "in", "self", ".", "residues", "[", "res...
Remove all non amino acid residues
[ "Remove", "all", "non", "amino", "acid", "residues" ]
[ "\"\"\"Remove all non amino acid residues\"\"\"" ]
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
b3736aea4b37ecf8a47ec3361bdb188dcfb75f73
shambo001/peat
Protool/structure.py
[ "MIT" ]
Python
remove_atoms_with_tag
<not_specific>
def remove_atoms_with_tag(self,tag=''): """Remove all atoms with the specified tag""" for atom in self.atoms.keys(): if self.atoms[atom].has_key('tag'): if self.atoms[atom]['tag']==tag: self.remove_atom(atom) return
Remove all atoms with the specified tag
Remove all atoms with the specified tag
[ "Remove", "all", "atoms", "with", "the", "specified", "tag" ]
def remove_atoms_with_tag(self,tag=''): for atom in self.atoms.keys(): if self.atoms[atom].has_key('tag'): if self.atoms[atom]['tag']==tag: self.remove_atom(atom) return
[ "def", "remove_atoms_with_tag", "(", "self", ",", "tag", "=", "''", ")", ":", "for", "atom", "in", "self", ".", "atoms", ".", "keys", "(", ")", ":", "if", "self", ".", "atoms", "[", "atom", "]", ".", "has_key", "(", "'tag'", ")", ":", "if", "self...
Remove all atoms with the specified tag
[ "Remove", "all", "atoms", "with", "the", "specified", "tag" ]
[ "\"\"\"Remove all atoms with the specified tag\"\"\"" ]
[ { "param": "self", "type": null }, { "param": "tag", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "tag", "type": null, "docstring": null, "docstring_tokens": []...
b3736aea4b37ecf8a47ec3361bdb188dcfb75f73
shambo001/peat
Protool/structure.py
[ "MIT" ]
Python
make_boxes
<not_specific>
def make_boxes(self): """Divide all atoms into 6A boxes""" self.boxes={} self.small_boxes={} for atom in self.atoms: x_index=int(self.atoms[atom]['X']/6.0) y_index=int(self.atoms[atom]['Y']/6.0) z_index=int(self.atoms[atom]['Z']/6.0) index=...
Divide all atoms into 6A boxes
Divide all atoms into 6A boxes
[ "Divide", "all", "atoms", "into", "6A", "boxes" ]
def make_boxes(self): self.boxes={} self.small_boxes={} for atom in self.atoms: x_index=int(self.atoms[atom]['X']/6.0) y_index=int(self.atoms[atom]['Y']/6.0) z_index=int(self.atoms[atom]['Z']/6.0) index='%d_%d_%d' %(x_index,y_index,z_index) ...
[ "def", "make_boxes", "(", "self", ")", ":", "self", ".", "boxes", "=", "{", "}", "self", ".", "small_boxes", "=", "{", "}", "for", "atom", "in", "self", ".", "atoms", ":", "x_index", "=", "int", "(", "self", ".", "atoms", "[", "atom", "]", "[", ...
Divide all atoms into 6A boxes
[ "Divide", "all", "atoms", "into", "6A", "boxes" ]
[ "\"\"\"Divide all atoms into 6A boxes\"\"\"", "#", "#", "# --- Now the smaller box", "#", "#" ]
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
b3736aea4b37ecf8a47ec3361bdb188dcfb75f73
shambo001/peat
Protool/structure.py
[ "MIT" ]
Python
hasMissingMainChainAtoms
<not_specific>
def hasMissingMainChainAtoms(self): """Check that each amino acid residue has all heavy main chain atoms""" missing=[] for residue in self.residues.keys(): if not self.isaa(residue): continue for atom in ['O','C','CA','N']: if not '%s:%s' %...
Check that each amino acid residue has all heavy main chain atoms
Check that each amino acid residue has all heavy main chain atoms
[ "Check", "that", "each", "amino", "acid", "residue", "has", "all", "heavy", "main", "chain", "atoms" ]
def hasMissingMainChainAtoms(self): missing=[] for residue in self.residues.keys(): if not self.isaa(residue): continue for atom in ['O','C','CA','N']: if not '%s:%s' %(residue,atom) in self.residues[residue]: missing.append('%s...
[ "def", "hasMissingMainChainAtoms", "(", "self", ")", ":", "missing", "=", "[", "]", "for", "residue", "in", "self", ".", "residues", ".", "keys", "(", ")", ":", "if", "not", "self", ".", "isaa", "(", "residue", ")", ":", "continue", "for", "atom", "i...
Check that each amino acid residue has all heavy main chain atoms
[ "Check", "that", "each", "amino", "acid", "residue", "has", "all", "heavy", "main", "chain", "atoms" ]
[ "\"\"\"Check that each amino acid residue has all heavy main chain atoms\"\"\"" ]
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
b3736aea4b37ecf8a47ec3361bdb188dcfb75f73
shambo001/peat
Protool/structure.py
[ "MIT" ]
Python
hasChainBreak
<not_specific>
def hasChainBreak(self): """Check if the soup contains chains with chain breaks""" for chain in self.chains.keys(): residues=sorted(self.chains[chain]) Cterms=0 Nterms=0 for residue in residues: if not self.isaa(residue): ...
Check if the soup contains chains with chain breaks
Check if the soup contains chains with chain breaks
[ "Check", "if", "the", "soup", "contains", "chains", "with", "chain", "breaks" ]
def hasChainBreak(self): for chain in self.chains.keys(): residues=sorted(self.chains[chain]) Cterms=0 Nterms=0 for residue in residues: if not self.isaa(residue): continue try: nextres=self.N...
[ "def", "hasChainBreak", "(", "self", ")", ":", "for", "chain", "in", "self", ".", "chains", ".", "keys", "(", ")", ":", "residues", "=", "sorted", "(", "self", ".", "chains", "[", "chain", "]", ")", "Cterms", "=", "0", "Nterms", "=", "0", "for", ...
Check if the soup contains chains with chain breaks
[ "Check", "if", "the", "soup", "contains", "chains", "with", "chain", "breaks" ]
[ "\"\"\"Check if the soup contains chains with chain breaks\"\"\"" ]
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
b3736aea4b37ecf8a47ec3361bdb188dcfb75f73
shambo001/peat
Protool/structure.py
[ "MIT" ]
Python
readpdb
<not_specific>
def readpdb(self,filename=None,data=None,parse=1,readmodels=1,use_NMRnumber=True): """ # Reads a pdb file and lets PDBparser.parse do the parsing """ import os if data != None: import StringIO stream = StringIO.StringIO(data) self.l...
# Reads a pdb file and lets PDBparser.parse do the parsing
Reads a pdb file and lets PDBparser.parse do the parsing
[ "Reads", "a", "pdb", "file", "and", "lets", "PDBparser", ".", "parse", "do", "the", "parsing" ]
def readpdb(self,filename=None,data=None,parse=1,readmodels=1,use_NMRnumber=True): import os if data != None: import StringIO stream = StringIO.StringIO(data) self.lines = stream.readlines() elif os.path.isfile(filename): if...
[ "def", "readpdb", "(", "self", ",", "filename", "=", "None", ",", "data", "=", "None", ",", "parse", "=", "1", ",", "readmodels", "=", "1", ",", "use_NMRnumber", "=", "True", ")", ":", "import", "os", "if", "data", "!=", "None", ":", "import", "Str...
Reads a pdb file and lets PDBparser.parse do the parsing
[ "Reads", "a", "pdb", "file", "and", "lets", "PDBparser", ".", "parse", "do", "the", "parsing" ]
[ "\"\"\"\n # Reads a pdb file and lets PDBparser.parse do the parsing\n \"\"\"", "#", "# Transfer spacegroup info", "#", "# Transfer crystal symmetry info", "#", "#", "# Update", "#" ]
[ { "param": "self", "type": null }, { "param": "filename", "type": null }, { "param": "data", "type": null }, { "param": "parse", "type": null }, { "param": "readmodels", "type": null }, { "param": "use_NMRnumber", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "filename", "type": null, "docstring": null, "docstring_tokens...
b3736aea4b37ecf8a47ec3361bdb188dcfb75f73
shambo001/peat
Protool/structure.py
[ "MIT" ]
Python
renumber_atoms
<not_specific>
def renumber_atoms(self): """Renumber all atoms based on their names""" count=0 atoms=self.atoms.keys() atoms.sort() for atom in atoms: self.atoms[atom]['NUMBER']=count+1 count=count+1 return
Renumber all atoms based on their names
Renumber all atoms based on their names
[ "Renumber", "all", "atoms", "based", "on", "their", "names" ]
def renumber_atoms(self): count=0 atoms=self.atoms.keys() atoms.sort() for atom in atoms: self.atoms[atom]['NUMBER']=count+1 count=count+1 return
[ "def", "renumber_atoms", "(", "self", ")", ":", "count", "=", "0", "atoms", "=", "self", ".", "atoms", ".", "keys", "(", ")", "atoms", ".", "sort", "(", ")", "for", "atom", "in", "atoms", ":", "self", ".", "atoms", "[", "atom", "]", "[", "'NUMBER...
Renumber all atoms based on their names
[ "Renumber", "all", "atoms", "based", "on", "their", "names" ]
[ "\"\"\"Renumber all atoms based on their names\"\"\"" ]
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
b3736aea4b37ecf8a47ec3361bdb188dcfb75f73
shambo001/peat
Protool/structure.py
[ "MIT" ]
Python
writepdb
<not_specific>
def writepdb(self,filename,header=None,nowrite=False,dont_write_HETATMS=None,TER=1,pqr=None,style=None): """ # Writes a PDB file from the informations in self.atoms """ # # Renumber all atoms first # self.renumber_atoms() # # Write the file ...
# Writes a PDB file from the informations in self.atoms
Writes a PDB file from the informations in self.atoms
[ "Writes", "a", "PDB", "file", "from", "the", "informations", "in", "self", ".", "atoms" ]
def writepdb(self,filename,header=None,nowrite=False,dont_write_HETATMS=None,TER=1,pqr=None,style=None): Renumber all atoms first self.renumber_atoms() Write the file class virtual_file: def __init__(self): self.lines=[] def write(self,text): ...
[ "def", "writepdb", "(", "self", ",", "filename", ",", "header", "=", "None", ",", "nowrite", "=", "False", ",", "dont_write_HETATMS", "=", "None", ",", "TER", "=", "1", ",", "pqr", "=", "None", ",", "style", "=", "None", ")", ":", "self", ".", "ren...
Writes a PDB file from the informations in self.atoms
[ "Writes", "a", "PDB", "file", "from", "the", "informations", "in", "self", ".", "atoms" ]
[ "\"\"\"\n # Writes a PDB file from the informations in self.atoms\n \"\"\"", "#", "# Renumber all atoms first", "#", "#", "# Write the file", "#", "#", "#", "#", "#", "# Continue", "#", "#", "# Write the cryst info", "#", "#", "# Now write atoms", "#", "#", "# S...
[ { "param": "self", "type": null }, { "param": "filename", "type": null }, { "param": "header", "type": null }, { "param": "nowrite", "type": null }, { "param": "dont_write_HETATMS", "type": null }, { "param": "TER", "type": null }, { "param...
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "filename", "type": null, "docstring": null, "docstring_tokens...
b3736aea4b37ecf8a47ec3361bdb188dcfb75f73
shambo001/peat
Protool/structure.py
[ "MIT" ]
Python
parsepdb
<not_specific>
def parsepdb(self,lines): """ Parses a PDB file, which is contained in lines (a list of lines) """ import PDBparser Y=PDBparser.PDBparser(lines,self.parse_terms) Y.parse() self.atoms=Y.atoms self.Update() self.attribute=Y.attribute ...
Parses a PDB file, which is contained in lines (a list of lines)
Parses a PDB file, which is contained in lines (a list of lines)
[ "Parses", "a", "PDB", "file", "which", "is", "contained", "in", "lines", "(", "a", "list", "of", "lines", ")" ]
def parsepdb(self,lines): import PDBparser Y=PDBparser.PDBparser(lines,self.parse_terms) Y.parse() self.atoms=Y.atoms self.Update() self.attribute=Y.attribute return
[ "def", "parsepdb", "(", "self", ",", "lines", ")", ":", "import", "PDBparser", "Y", "=", "PDBparser", ".", "PDBparser", "(", "lines", ",", "self", ".", "parse_terms", ")", "Y", ".", "parse", "(", ")", "self", ".", "atoms", "=", "Y", ".", "atoms", "...
Parses a PDB file, which is contained in lines (a list of lines)
[ "Parses", "a", "PDB", "file", "which", "is", "contained", "in", "lines", "(", "a", "list", "of", "lines", ")" ]
[ "\"\"\"\n Parses a PDB file, which is contained in lines (a list of lines)\n \"\"\"" ]
[ { "param": "self", "type": null }, { "param": "lines", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "lines", "type": null, "docstring": null, "docstring_tokens": ...
b3736aea4b37ecf8a47ec3361bdb188dcfb75f73
shambo001/peat
Protool/structure.py
[ "MIT" ]
Python
addpdblines
<not_specific>
def addpdblines(self,lines): """Add the atoms in lines to the current set of atoms""" import PDBparser Y=PDBparser.PDBparser(lines,self.parse_terms) Y.parse() error=False for atom in Y.atoms.keys(): if not self.atoms.has_key(atom): self.atoms[a...
Add the atoms in lines to the current set of atoms
Add the atoms in lines to the current set of atoms
[ "Add", "the", "atoms", "in", "lines", "to", "the", "current", "set", "of", "atoms" ]
def addpdblines(self,lines): import PDBparser Y=PDBparser.PDBparser(lines,self.parse_terms) Y.parse() error=False for atom in Y.atoms.keys(): if not self.atoms.has_key(atom): self.atoms[atom]=Y.atoms[atom] else: print 'Name ...
[ "def", "addpdblines", "(", "self", ",", "lines", ")", ":", "import", "PDBparser", "Y", "=", "PDBparser", ".", "PDBparser", "(", "lines", ",", "self", ".", "parse_terms", ")", "Y", ".", "parse", "(", ")", "error", "=", "False", "for", "atom", "in", "Y...
Add the atoms in lines to the current set of atoms
[ "Add", "the", "atoms", "in", "lines", "to", "the", "current", "set", "of", "atoms" ]
[ "\"\"\"Add the atoms in lines to the current set of atoms\"\"\"" ]
[ { "param": "self", "type": null }, { "param": "lines", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "lines", "type": null, "docstring": null, "docstring_tokens": ...
b37bde73a40919c61d69bb150590b71dff8b0ed9
shambo001/peat
pKaTool/pKaTool_main.py
[ "MIT" ]
Python
mult_calc_anal
<not_specific>
def mult_calc_anal(self,event=None): """Open the multiple calc analysis window""" import multiple_calc_analysis multiple_calc_analysis.multiple_calc_analysis(self) return
Open the multiple calc analysis window
Open the multiple calc analysis window
[ "Open", "the", "multiple", "calc", "analysis", "window" ]
def mult_calc_anal(self,event=None): import multiple_calc_analysis multiple_calc_analysis.multiple_calc_analysis(self) return
[ "def", "mult_calc_anal", "(", "self", ",", "event", "=", "None", ")", ":", "import", "multiple_calc_analysis", "multiple_calc_analysis", ".", "multiple_calc_analysis", "(", "self", ")", "return" ]
Open the multiple calc analysis window
[ "Open", "the", "multiple", "calc", "analysis", "window" ]
[ "\"\"\"Open the multiple calc analysis window\"\"\"" ]
[ { "param": "self", "type": null }, { "param": "event", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "event", "type": null, "docstring": null, "docstring_tokens": ...
b37bde73a40919c61d69bb150590b71dff8b0ed9
shambo001/peat
pKaTool/pKaTool_main.py
[ "MIT" ]
Python
add_to_pulldown
<not_specific>
def add_to_pulldown(self,pdbfilename,label): """Add a new titration to the menus""" self.calc_disp[pdbfilename]=IntVar() self.display_menu.add_checkbutton(label=label+':'+pdbfilename, variable=self.calc_disp[pdbfilename], ...
Add a new titration to the menus
Add a new titration to the menus
[ "Add", "a", "new", "titration", "to", "the", "menus" ]
def add_to_pulldown(self,pdbfilename,label): self.calc_disp[pdbfilename]=IntVar() self.display_menu.add_checkbutton(label=label+':'+pdbfilename, variable=self.calc_disp[pdbfilename], onvalue=1,offvalue=0, ...
[ "def", "add_to_pulldown", "(", "self", ",", "pdbfilename", ",", "label", ")", ":", "self", ".", "calc_disp", "[", "pdbfilename", "]", "=", "IntVar", "(", ")", "self", ".", "display_menu", ".", "add_checkbutton", "(", "label", "=", "label", "+", "':'", "+...
Add a new titration to the menus
[ "Add", "a", "new", "titration", "to", "the", "menus" ]
[ "\"\"\"Add a new titration to the menus\"\"\"", "#", "# Now the select menu", "#" ]
[ { "param": "self", "type": null }, { "param": "pdbfilename", "type": null }, { "param": "label", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "pdbfilename", "type": null, "docstring": null, "docstring_tok...
b37bde73a40919c61d69bb150590b71dff8b0ed9
shambo001/peat
pKaTool/pKaTool_main.py
[ "MIT" ]
Python
update_all_groups
<not_specific>
def update_all_groups(self,event=None): """Update the listbox showing the groups for the selected calculation""" # # Add the groups to the listbox # self.group_disp.delete(0, END) for group in self.groups: self.group_disp.insert(END,group) return
Update the listbox showing the groups for the selected calculation
Update the listbox showing the groups for the selected calculation
[ "Update", "the", "listbox", "showing", "the", "groups", "for", "the", "selected", "calculation" ]
def update_all_groups(self,event=None): Add the groups to the listbox self.group_disp.delete(0, END) for group in self.groups: self.group_disp.insert(END,group) return
[ "def", "update_all_groups", "(", "self", ",", "event", "=", "None", ")", ":", "self", ".", "group_disp", ".", "delete", "(", "0", ",", "END", ")", "for", "group", "in", "self", ".", "groups", ":", "self", ".", "group_disp", ".", "insert", "(", "END",...
Update the listbox showing the groups for the selected calculation
[ "Update", "the", "listbox", "showing", "the", "groups", "for", "the", "selected", "calculation" ]
[ "\"\"\"Update the listbox showing the groups for the selected calculation\"\"\"", "#", "# Add the groups to the listbox", "#" ]
[ { "param": "self", "type": null }, { "param": "event", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "event", "type": null, "docstring": null, "docstring_tokens": ...
b37bde73a40919c61d69bb150590b71dff8b0ed9
shambo001/peat
pKaTool/pKaTool_main.py
[ "MIT" ]
Python
update_selected_calc
<not_specific>
def update_selected_calc(self,event=None): """Update the set of pKa values we're working with""" # # First store the selected groups from the old selection # if self.current_selected_calc: self.calcs[self.current_selected_calc]['selected_groups']=self.selected_groups[...
Update the set of pKa values we're working with
Update the set of pKa values we're working with
[ "Update", "the", "set", "of", "pKa", "values", "we", "'", "re", "working", "with" ]
def update_selected_calc(self,event=None): First store the selected groups from the old selection if self.current_selected_calc: self.calcs[self.current_selected_calc]['selected_groups']=self.selected_groups[:] Then load the new stuff new_calc=self.calc_select.get() ...
[ "def", "update_selected_calc", "(", "self", ",", "event", "=", "None", ")", ":", "if", "self", ".", "current_selected_calc", ":", "self", ".", "calcs", "[", "self", ".", "current_selected_calc", "]", "[", "'selected_groups'", "]", "=", "self", ".", "selected...
Update the set of pKa values we're working with
[ "Update", "the", "set", "of", "pKa", "values", "we", "'", "re", "working", "with" ]
[ "\"\"\"Update the set of pKa values we're working with\"\"\"", "#", "# First store the selected groups from the old selection", "#", "#", "# Then load the new stuff", "#", "#", "#", "# Update the selection and all groups", "#", "#", "# Set pdbfilename", "#", "#", "# Read the PDB file",...
[ { "param": "self", "type": null }, { "param": "event", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "event", "type": null, "docstring": null, "docstring_tokens": ...
b37bde73a40919c61d69bb150590b71dff8b0ed9
shambo001/peat
pKaTool/pKaTool_main.py
[ "MIT" ]
Python
select_all
<not_specific>
def select_all(self,event=None): """Select all groups in the window""" count=0 for group in self.groups: self.group_disp.selection_set(count) count=count+1 return
Select all groups in the window
Select all groups in the window
[ "Select", "all", "groups", "in", "the", "window" ]
def select_all(self,event=None): count=0 for group in self.groups: self.group_disp.selection_set(count) count=count+1 return
[ "def", "select_all", "(", "self", ",", "event", "=", "None", ")", ":", "count", "=", "0", "for", "group", "in", "self", ".", "groups", ":", "self", ".", "group_disp", ".", "selection_set", "(", "count", ")", "count", "=", "count", "+", "1", "return" ...
Select all groups in the window
[ "Select", "all", "groups", "in", "the", "window" ]
[ "\"\"\"Select all groups in the window\"\"\"" ]
[ { "param": "self", "type": null }, { "param": "event", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "event", "type": null, "docstring": null, "docstring_tokens": ...
b37bde73a40919c61d69bb150590b71dff8b0ed9
shambo001/peat
pKaTool/pKaTool_main.py
[ "MIT" ]
Python
select_group
<not_specific>
def select_group(self): """Transfer the selected group to the 'selected' window""" for sel in self.group_disp.curselection(): group_num=int(sel) sel_group=self.groups[group_num] if not sel_group in self.selected_groups: self.selected_groups.append(sel_...
Transfer the selected group to the 'selected' window
Transfer the selected group to the 'selected' window
[ "Transfer", "the", "selected", "group", "to", "the", "'", "selected", "'", "window" ]
def select_group(self): for sel in self.group_disp.curselection(): group_num=int(sel) sel_group=self.groups[group_num] if not sel_group in self.selected_groups: self.selected_groups.append(sel_group) self.update_selected_groups() return
[ "def", "select_group", "(", "self", ")", ":", "for", "sel", "in", "self", ".", "group_disp", ".", "curselection", "(", ")", ":", "group_num", "=", "int", "(", "sel", ")", "sel_group", "=", "self", ".", "groups", "[", "group_num", "]", "if", "not", "s...
Transfer the selected group to the 'selected' window
[ "Transfer", "the", "selected", "group", "to", "the", "'", "selected", "'", "window" ]
[ "\"\"\"Transfer the selected group to the 'selected' window\"\"\"" ]
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
b37bde73a40919c61d69bb150590b71dff8b0ed9
shambo001/peat
pKaTool/pKaTool_main.py
[ "MIT" ]
Python
select_irregular_titcurvs
<not_specific>
def select_irregular_titcurvs(self): """Select irregular titration curves based on a fit to the Henderson-Hasselbalch equation""" self.selected_groups=[] import pKarun.pKa_general X=pKarun.pKa_general.pKanalyse() for group in self.groups: # # Include only ...
Select irregular titration curves based on a fit to the Henderson-Hasselbalch equation
Select irregular titration curves based on a fit to the Henderson-Hasselbalch equation
[ "Select", "irregular", "titration", "curves", "based", "on", "a", "fit", "to", "the", "Henderson", "-", "Hasselbalch", "equation" ]
def select_irregular_titcurvs(self): self.selected_groups=[] import pKarun.pKa_general X=pKarun.pKa_general.pKanalyse() for group in self.groups: Include only groups with a pKa value if self.pkavals[group]['pKa']: solution,sq=X.fit_to_henderson(se...
[ "def", "select_irregular_titcurvs", "(", "self", ")", ":", "self", ".", "selected_groups", "=", "[", "]", "import", "pKarun", ".", "pKa_general", "X", "=", "pKarun", ".", "pKa_general", ".", "pKanalyse", "(", ")", "for", "group", "in", "self", ".", "groups...
Select irregular titration curves based on a fit to the Henderson-Hasselbalch equation
[ "Select", "irregular", "titration", "curves", "based", "on", "a", "fit", "to", "the", "Henderson", "-", "Hasselbalch", "equation" ]
[ "\"\"\"Select irregular titration curves based on a fit to the Henderson-Hasselbalch equation\"\"\"", "#", "# Include only groups with a pKa value", "#" ]
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
b37bde73a40919c61d69bb150590b71dff8b0ed9
shambo001/peat
pKaTool/pKaTool_main.py
[ "MIT" ]
Python
display_details_sel
<not_specific>
def display_details_sel(self,event=None): """Display the details of the groups clicked in the selected window""" self.details.delete(1.0, END) # # Loop over all groups # for sel in self.selected.curselection(): group_num=int(sel) group=self.selecte...
Display the details of the groups clicked in the selected window
Display the details of the groups clicked in the selected window
[ "Display", "the", "details", "of", "the", "groups", "clicked", "in", "the", "selected", "window" ]
def display_details_sel(self,event=None): self.details.delete(1.0, END) Loop over all groups for sel in self.selected.curselection(): group_num=int(sel) group=self.selected_groups[group_num] self.add_group_to_details(group) return
[ "def", "display_details_sel", "(", "self", ",", "event", "=", "None", ")", ":", "self", ".", "details", ".", "delete", "(", "1.0", ",", "END", ")", "for", "sel", "in", "self", ".", "selected", ".", "curselection", "(", ")", ":", "group_num", "=", "in...
Display the details of the groups clicked in the selected window
[ "Display", "the", "details", "of", "the", "groups", "clicked", "in", "the", "selected", "window" ]
[ "\"\"\"Display the details of the groups clicked in the selected window\"\"\"", "#", "# Loop over all groups", "#" ]
[ { "param": "self", "type": null }, { "param": "event", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "event", "type": null, "docstring": null, "docstring_tokens": ...
b37bde73a40919c61d69bb150590b71dff8b0ed9
shambo001/peat
pKaTool/pKaTool_main.py
[ "MIT" ]
Python
display_details
<not_specific>
def display_details(self,event=None): """Display the details of the groups clicked in the list of all groups""" # # Do the details # self.details.delete(1.0, END) # # Loop over all groups # for sel in self.group_disp.curselection(): gro...
Display the details of the groups clicked in the list of all groups
Display the details of the groups clicked in the list of all groups
[ "Display", "the", "details", "of", "the", "groups", "clicked", "in", "the", "list", "of", "all", "groups" ]
def display_details(self,event=None): Do the details self.details.delete(1.0, END) Loop over all groups for sel in self.group_disp.curselection(): group_num=int(sel) group=self.groups[group_num] self.add_group_to_details(group) return
[ "def", "display_details", "(", "self", ",", "event", "=", "None", ")", ":", "self", ".", "details", ".", "delete", "(", "1.0", ",", "END", ")", "for", "sel", "in", "self", ".", "group_disp", ".", "curselection", "(", ")", ":", "group_num", "=", "int"...
Display the details of the groups clicked in the list of all groups
[ "Display", "the", "details", "of", "the", "groups", "clicked", "in", "the", "list", "of", "all", "groups" ]
[ "\"\"\"Display the details of the groups clicked in the list of all groups\"\"\"", "#", "# Do the details", "#", "#", "# Loop over all groups", "#" ]
[ { "param": "self", "type": null }, { "param": "event", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "event", "type": null, "docstring": null, "docstring_tokens": ...
b37bde73a40919c61d69bb150590b71dff8b0ed9
shambo001/peat
pKaTool/pKaTool_main.py
[ "MIT" ]
Python
add_group_to_details
<not_specific>
def add_group_to_details(self,group): """Add the details of a single group to the details window""" X=pKarun.pKa_general.pKanalyse() order=['modelpK','desolv','backgr','intpKa','delec','dpKa','pKa'] unit_dict={'modelpK':'','desolv':'pKa units','backgr':'pKa units','delec':'pKa units','dp...
Add the details of a single group to the details window
Add the details of a single group to the details window
[ "Add", "the", "details", "of", "a", "single", "group", "to", "the", "details", "window" ]
def add_group_to_details(self,group): X=pKarun.pKa_general.pKanalyse() order=['modelpK','desolv','backgr','intpKa','delec','dpKa','pKa'] unit_dict={'modelpK':'','desolv':'pKa units','backgr':'pKa units','delec':'pKa units','dpKa':'pKa units','pKa':'','intpKa':''} self.details.insert(END,...
[ "def", "add_group_to_details", "(", "self", ",", "group", ")", ":", "X", "=", "pKarun", ".", "pKa_general", ".", "pKanalyse", "(", ")", "order", "=", "[", "'modelpK'", ",", "'desolv'", ",", "'backgr'", ",", "'intpKa'", ",", "'delec'", ",", "'dpKa'", ",",...
Add the details of a single group to the details window
[ "Add", "the", "details", "of", "a", "single", "group", "to", "the", "details", "window" ]
[ "\"\"\"Add the details of a single group to the details window\"\"\"", "#", "# Insert the text", "#", "#", "# Insert the fit to the Henderson-Hasselbalch equation", "#" ]
[ { "param": "self", "type": null }, { "param": "group", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "group", "type": null, "docstring": null, "docstring_tokens": ...
b37bde73a40919c61d69bb150590b71dff8b0ed9
shambo001/peat
pKaTool/pKaTool_main.py
[ "MIT" ]
Python
show_matrix_table
<not_specific>
def show_matrix_table(self,event=None): """Open a new window with the matrix for all selected groups""" details_win=Toplevel() import pKarun.pKa_general X=pKarun.pKa_general.pKanalyse() row=0 order=sorted(self.matrix.keys()) # # Insert table headings ...
Open a new window with the matrix for all selected groups
Open a new window with the matrix for all selected groups
[ "Open", "a", "new", "window", "with", "the", "matrix", "for", "all", "selected", "groups" ]
def show_matrix_table(self,event=None): details_win=Toplevel() import pKarun.pKa_general X=pKarun.pKa_general.pKanalyse() row=0 order=sorted(self.matrix.keys()) Insert table headings column=0 for key in ['dpKa units']+order: tl=Label(details_w...
[ "def", "show_matrix_table", "(", "self", ",", "event", "=", "None", ")", ":", "details_win", "=", "Toplevel", "(", ")", "import", "pKarun", ".", "pKa_general", "X", "=", "pKarun", ".", "pKa_general", ".", "pKanalyse", "(", ")", "row", "=", "0", "order", ...
Open a new window with the matrix for all selected groups
[ "Open", "a", "new", "window", "with", "the", "matrix", "for", "all", "selected", "groups" ]
[ "\"\"\"Open a new window with the matrix for all selected groups\"\"\"", "#", "# Insert table headings", "#", "#", "# Insert the data", "#", "#", "# Fill the cell", "#", "#" ]
[ { "param": "self", "type": null }, { "param": "event", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "event", "type": null, "docstring": null, "docstring_tokens": ...
b37bde73a40919c61d69bb150590b71dff8b0ed9
shambo001/peat
pKaTool/pKaTool_main.py
[ "MIT" ]
Python
show_details_table
<not_specific>
def show_details_table(self,event=None): """Open a new window with all details for the groups selected""" details_win=Toplevel() import pKarun.pKa_general X=pKarun.pKa_general.pKanalyse() row=0 order=['Group','modelpK','desolv','backgr','intpKa','delec','dpKa','pKa','HH f...
Open a new window with all details for the groups selected
Open a new window with all details for the groups selected
[ "Open", "a", "new", "window", "with", "all", "details", "for", "the", "groups", "selected" ]
def show_details_table(self,event=None): details_win=Toplevel() import pKarun.pKa_general X=pKarun.pKa_general.pKanalyse() row=0 order=['Group','modelpK','desolv','backgr','intpKa','delec','dpKa','pKa','HH fit','HH fit pKa'] Insert table headings column=0 ...
[ "def", "show_details_table", "(", "self", ",", "event", "=", "None", ")", ":", "details_win", "=", "Toplevel", "(", ")", "import", "pKarun", ".", "pKa_general", "X", "=", "pKarun", ".", "pKa_general", ".", "pKanalyse", "(", ")", "row", "=", "0", "order",...
Open a new window with all details for the groups selected
[ "Open", "a", "new", "window", "with", "all", "details", "for", "the", "groups", "selected" ]
[ "\"\"\"Open a new window with all details for the groups selected\"\"\"", "#", "# Insert table headings", "#", "#", "# Insert the data", "#", "#", "# We've already inserted the name, and we will insert the HH parms later", "#", "#", "# Inser the rest", "#", "# Insert the text", "#", "#...
[ { "param": "self", "type": null }, { "param": "event", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "event", "type": null, "docstring": null, "docstring_tokens": ...
b37bde73a40919c61d69bb150590b71dff8b0ed9
shambo001/peat
pKaTool/pKaTool_main.py
[ "MIT" ]
Python
update_selected_groups
<not_specific>
def update_selected_groups(self): """Update the display in the main window - both the list of groups, and the drawing of titration curves""" # # Sort # self.selected_groups.sort() self.selected.delete(0, END) for group in self.selected_groups: self.sel...
Update the display in the main window - both the list of groups, and the drawing of titration curves
Update the display in the main window - both the list of groups, and the drawing of titration curves
[ "Update", "the", "display", "in", "the", "main", "window", "-", "both", "the", "list", "of", "groups", "and", "the", "drawing", "of", "titration", "curves" ]
def update_selected_groups(self): Sort self.selected_groups.sort() self.selected.delete(0, END) for group in self.selected_groups: self.selected.insert(END,group) Copy it to the master array self.calcs[self.current_selected_calc]['selected_groups']=self.sele...
[ "def", "update_selected_groups", "(", "self", ")", ":", "self", ".", "selected_groups", ".", "sort", "(", ")", "self", ".", "selected", ".", "delete", "(", "0", ",", "END", ")", "for", "group", "in", "self", ".", "selected_groups", ":", "self", ".", "s...
Update the display in the main window - both the list of groups, and the drawing of titration curves
[ "Update", "the", "display", "in", "the", "main", "window", "-", "both", "the", "list", "of", "groups", "and", "the", "drawing", "of", "titration", "curves" ]
[ "\"\"\"Update the display in the main window - both the list of groups, and the drawing of titration curves\"\"\"", "#", "# Sort", "#", "#", "# Copy it to the master array", "#", "#", "# Redraw the titration curves", "#", "#", "# Update the drawing of curves", "#", "#", "# If we are show...
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
b37bde73a40919c61d69bb150590b71dff8b0ed9
shambo001/peat
pKaTool/pKaTool_main.py
[ "MIT" ]
Python
model_rest_of_protein
<not_specific>
def model_rest_of_protein(self,model,set_pH): """Compile the information for modelling the rest of teh protein model 0 = ignore model 1 = non-titrating point charges (select charge at pH 7.0) model 2 = fixed titrating charges """ wait_win=Toplevel() self.set_geome...
Compile the information for modelling the rest of teh protein model 0 = ignore model 1 = non-titrating point charges (select charge at pH 7.0) model 2 = fixed titrating charges
Compile the information for modelling the rest of teh protein model 0 = ignore model 1 = non-titrating point charges (select charge at pH 7.0) model 2 = fixed titrating charges
[ "Compile", "the", "information", "for", "modelling", "the", "rest", "of", "teh", "protein", "model", "0", "=", "ignore", "model", "1", "=", "non", "-", "titrating", "point", "charges", "(", "select", "charge", "at", "pH", "7", ".", "0", ")", "model", "...
def model_rest_of_protein(self,model,set_pH): wait_win=Toplevel() self.set_geometry(self.master,wait_win) wait_win.title('Please wait') Label(wait_win,text='Calculating cumulated effect of all other groups').grid(row=0,column=0) self.master.update_idletasks() wait_win.upd...
[ "def", "model_rest_of_protein", "(", "self", ",", "model", ",", "set_pH", ")", ":", "wait_win", "=", "Toplevel", "(", ")", "self", ".", "set_geometry", "(", "self", ".", "master", ",", "wait_win", ")", "wait_win", ".", "title", "(", "'Please wait'", ")", ...
Compile the information for modelling the rest of teh protein model 0 = ignore model 1 = non-titrating point charges (select charge at pH 7.0) model 2 = fixed titrating charges
[ "Compile", "the", "information", "for", "modelling", "the", "rest", "of", "teh", "protein", "model", "0", "=", "ignore", "model", "1", "=", "non", "-", "titrating", "point", "charges", "(", "select", "charge", "at", "pH", "7", ".", "0", ")", "model", "...
[ "\"\"\"Compile the information for modelling the rest of teh protein\n model 0 = ignore\n model 1 = non-titrating point charges (select charge at pH 7.0)\n model 2 = fixed titrating charges\n \"\"\"", "#", "# Initialise the array that holds information on all other groups", "#", ...
[ { "param": "self", "type": null }, { "param": "model", "type": null }, { "param": "set_pH", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "model", "type": null, "docstring": null, "docstring_tokens": ...
b37bde73a40919c61d69bb150590b71dff8b0ed9
shambo001/peat
pKaTool/pKaTool_main.py
[ "MIT" ]
Python
goto_pKa_system
<not_specific>
def goto_pKa_system(self): """Open dialog asking for how many groups""" import tkSimpleDialog num_groups=tkSimpleDialog.askinteger("Number of groups","Please enter number of titratable groups", parent=self.master) S=pKa_system.pKa_system(num_g...
Open dialog asking for how many groups
Open dialog asking for how many groups
[ "Open", "dialog", "asking", "for", "how", "many", "groups" ]
def goto_pKa_system(self): import tkSimpleDialog num_groups=tkSimpleDialog.askinteger("Number of groups","Please enter number of titratable groups", parent=self.master) S=pKa_system.pKa_system(num_groups,self.master) return
[ "def", "goto_pKa_system", "(", "self", ")", ":", "import", "tkSimpleDialog", "num_groups", "=", "tkSimpleDialog", ".", "askinteger", "(", "\"Number of groups\"", ",", "\"Please enter number of titratable groups\"", ",", "parent", "=", "self", ".", "master", ")", "S", ...
Open dialog asking for how many groups
[ "Open", "dialog", "asking", "for", "how", "many", "groups" ]
[ "\"\"\"Open dialog asking for how many groups\"\"\"" ]
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
b37bde73a40919c61d69bb150590b71dff8b0ed9
shambo001/peat
pKaTool/pKaTool_main.py
[ "MIT" ]
Python
select_strongly_interacting_groups
<not_specific>
def select_strongly_interacting_groups(self): """Select groups that interact strongly with the selected groups""" self.matrix=self.X.read_matrix() append_groups={} # # Loop over all selected groups and check for interaction energies # interaction_energy_cutoff=sel...
Select groups that interact strongly with the selected groups
Select groups that interact strongly with the selected groups
[ "Select", "groups", "that", "interact", "strongly", "with", "the", "selected", "groups" ]
def select_strongly_interacting_groups(self): self.matrix=self.X.read_matrix() append_groups={} Loop over all selected groups and check for interaction energies interaction_energy_cutoff=self.int_cutoff.get() for group_sel in self.selected_groups: self.selected_group...
[ "def", "select_strongly_interacting_groups", "(", "self", ")", ":", "self", ".", "matrix", "=", "self", ".", "X", ".", "read_matrix", "(", ")", "append_groups", "=", "{", "}", "interaction_energy_cutoff", "=", "self", ".", "int_cutoff", ".", "get", "(", ")",...
Select groups that interact strongly with the selected groups
[ "Select", "groups", "that", "interact", "strongly", "with", "the", "selected", "groups" ]
[ "\"\"\"Select groups that interact strongly with the selected groups\"\"\"", "#", "# Loop over all selected groups and check for interaction energies", "#", "#self.selected_groups.append(group)", "#", "# Loop over all groups", "#", "#", "# Found all, now add them", "#" ]
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
b37bde73a40919c61d69bb150590b71dff8b0ed9
shambo001/peat
pKaTool/pKaTool_main.py
[ "MIT" ]
Python
load_titration
<not_specific>
def load_titration(self,pdbfilename=None): """Load the results of a pKa calculation""" import os if not pdbfilename: pdbfilename=tkFileDialog.askopenfilename(defaultextension='.pdb', initialdir=os.getcwd(), ...
Load the results of a pKa calculation
Load the results of a pKa calculation
[ "Load", "the", "results", "of", "a", "pKa", "calculation" ]
def load_titration(self,pdbfilename=None): import os if not pdbfilename: pdbfilename=tkFileDialog.askopenfilename(defaultextension='.pdb', initialdir=os.getcwd(), filetypes=[("WHAT IF pK...
[ "def", "load_titration", "(", "self", ",", "pdbfilename", "=", "None", ")", ":", "import", "os", "if", "not", "pdbfilename", ":", "pdbfilename", "=", "tkFileDialog", ".", "askopenfilename", "(", "defaultextension", "=", "'.pdb'", ",", "initialdir", "=", "os", ...
Load the results of a pKa calculation
[ "Load", "the", "results", "of", "a", "pKa", "calculation" ]
[ "\"\"\"Load the results of a pKa calculation\"\"\"", "#", "# Did we get a name?", "#", "#", "# Is it a WHAT IF type file?", "#", "#", "# Open the file and assess status", "#", "#", "# Read the titration curve", "#", "#", "# read the pKa values", "#", "#", "# Store the PDB file", ...
[ { "param": "self", "type": null }, { "param": "pdbfilename", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "pdbfilename", "type": null, "docstring": null, "docstring_tok...
b37bde73a40919c61d69bb150590b71dff8b0ed9
shambo001/peat
pKaTool/pKaTool_main.py
[ "MIT" ]
Python
save_titration
<not_specific>
def save_titration(self): """Save all titrations in a pickled file""" import tkFileDialog, os, pickle savedir=os.getcwd() filename=tkFileDialog.asksaveasfilename(defaultextension=".ppc", initialfile='calculation1.ppc', ...
Save all titrations in a pickled file
Save all titrations in a pickled file
[ "Save", "all", "titrations", "in", "a", "pickled", "file" ]
def save_titration(self): import tkFileDialog, os, pickle savedir=os.getcwd() filename=tkFileDialog.asksaveasfilename(defaultextension=".ppc", initialfile='calculation1.ppc', initialdir=savedir, ...
[ "def", "save_titration", "(", "self", ")", ":", "import", "tkFileDialog", ",", "os", ",", "pickle", "savedir", "=", "os", ".", "getcwd", "(", ")", "filename", "=", "tkFileDialog", ".", "asksaveasfilename", "(", "defaultextension", "=", "\".ppc\"", ",", "init...
Save all titrations in a pickled file
[ "Save", "all", "titrations", "in", "a", "pickled", "file" ]
[ "\"\"\"Save all titrations in a pickled file\"\"\"", "#", "# Save in ppc format anyway", "#" ]
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
b37bde73a40919c61d69bb150590b71dff8b0ed9
shambo001/peat
pKaTool/pKaTool_main.py
[ "MIT" ]
Python
subtract_titration
<not_specific>
def subtract_titration(self): """Subtract the second pKa calculation from the first to find differences in titration curves""" # # Choose the calc to subtract from # self.choose_win=Toplevel() lbl=Label(self.choose_win,text='Which calculation should we subtract from %s' %...
Subtract the second pKa calculation from the first to find differences in titration curves
Subtract the second pKa calculation from the first to find differences in titration curves
[ "Subtract", "the", "second", "pKa", "calculation", "from", "the", "first", "to", "find", "differences", "in", "titration", "curves" ]
def subtract_titration(self): Choose the calc to subtract from self.choose_win=Toplevel() lbl=Label(self.choose_win,text='Which calculation should we subtract from %s' %self.calc_select.get()) lbl.grid(row=0,column=0,columnspan=4) self.sub_calc=StringVar() self.sub_calc....
[ "def", "subtract_titration", "(", "self", ")", ":", "self", ".", "choose_win", "=", "Toplevel", "(", ")", "lbl", "=", "Label", "(", "self", ".", "choose_win", ",", "text", "=", "'Which calculation should we subtract from %s'", "%", "self", ".", "calc_select", ...
Subtract the second pKa calculation from the first to find differences in titration curves
[ "Subtract", "the", "second", "pKa", "calculation", "from", "the", "first", "to", "find", "differences", "in", "titration", "curves" ]
[ "\"\"\"Subtract the second pKa calculation from the first to find differences in titration curves\"\"\"", "#", "# Choose the calc to subtract from", "#", "#", "# the menu", "#", "#", "# Create new set", "#", "#", "# Subtract the pKa values", "#", "#", "# Subtract the titration curves", ...
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
a75dd86c86dfca6d2cd0d66fab3036fdc3ceb053
shambo001/peat
DataPipeline/Importer.py
[ "MIT" ]
Python
guessRowStart
<not_specific>
def guessRowStart(self, lines): """If rowstart is not specified in config, it might be non-zero""" s = 0 for line in lines: if not self.checkEmptyRow(line): s+=1 else: self.rowstart = s return
If rowstart is not specified in config, it might be non-zero
If rowstart is not specified in config, it might be non-zero
[ "If", "rowstart", "is", "not", "specified", "in", "config", "it", "might", "be", "non", "-", "zero" ]
def guessRowStart(self, lines): s = 0 for line in lines: if not self.checkEmptyRow(line): s+=1 else: self.rowstart = s return
[ "def", "guessRowStart", "(", "self", ",", "lines", ")", ":", "s", "=", "0", "for", "line", "in", "lines", ":", "if", "not", "self", ".", "checkEmptyRow", "(", "line", ")", ":", "s", "+=", "1", "else", ":", "self", ".", "rowstart", "=", "s", "retu...
If rowstart is not specified in config, it might be non-zero
[ "If", "rowstart", "is", "not", "specified", "in", "config", "it", "might", "be", "non", "-", "zero" ]
[ "\"\"\"If rowstart is not specified in config, it might be non-zero\"\"\"" ]
[ { "param": "self", "type": null }, { "param": "lines", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "lines", "type": null, "docstring": null, "docstring_tokens": ...
a75dd86c86dfca6d2cd0d66fab3036fdc3ceb053
shambo001/peat
DataPipeline/Importer.py
[ "MIT" ]
Python
checkValue
<not_specific>
def checkValue(self, val, format=''): """Coerce a string to float if possible""" #add code to handle commas in thousand separators dec = self.decimalsymbol if format != '': return self.checkTime(val, format) if dec == '.': try: return floa...
Coerce a string to float if possible
Coerce a string to float if possible
[ "Coerce", "a", "string", "to", "float", "if", "possible" ]
def checkValue(self, val, format=''): dec = self.decimalsymbol if format != '': return self.checkTime(val, format) if dec == '.': try: return float(val) except: return None else: try: return f...
[ "def", "checkValue", "(", "self", ",", "val", ",", "format", "=", "''", ")", ":", "dec", "=", "self", ".", "decimalsymbol", "if", "format", "!=", "''", ":", "return", "self", ".", "checkTime", "(", "val", ",", "format", ")", "if", "dec", "==", "'.'...
Coerce a string to float if possible
[ "Coerce", "a", "string", "to", "float", "if", "possible" ]
[ "\"\"\"Coerce a string to float if possible\"\"\"", "#add code to handle commas in thousand separators", "#print e" ]
[ { "param": "self", "type": null }, { "param": "val", "type": null }, { "param": "format", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "val", "type": null, "docstring": null, "docstring_tokens": []...
a75dd86c86dfca6d2cd0d66fab3036fdc3ceb053
shambo001/peat
DataPipeline/Importer.py
[ "MIT" ]
Python
checkTime
<not_specific>
def checkTime(self, val, timeformat): """Coerce to a datetime object and return a value in seconds from some reference""" try: dt = datetime.datetime.strptime(val,timeformat) return dt except ValueError, e: print e return None
Coerce to a datetime object and return a value in seconds from some reference
Coerce to a datetime object and return a value in seconds from some reference
[ "Coerce", "to", "a", "datetime", "object", "and", "return", "a", "value", "in", "seconds", "from", "some", "reference" ]
def checkTime(self, val, timeformat): try: dt = datetime.datetime.strptime(val,timeformat) return dt except ValueError, e: print e return None
[ "def", "checkTime", "(", "self", ",", "val", ",", "timeformat", ")", ":", "try", ":", "dt", "=", "datetime", ".", "datetime", ".", "strptime", "(", "val", ",", "timeformat", ")", "return", "dt", "except", "ValueError", ",", "e", ":", "print", "e", "r...
Coerce to a datetime object and return a value in seconds from some reference
[ "Coerce", "to", "a", "datetime", "object", "and", "return", "a", "value", "in", "seconds", "from", "some", "reference" ]
[ "\"\"\"Coerce to a datetime object and return a value in seconds\n from some reference\"\"\"" ]
[ { "param": "self", "type": null }, { "param": "val", "type": null }, { "param": "timeformat", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "val", "type": null, "docstring": null, "docstring_tokens": []...
c19178b82aed4697ad34f77c541ab11a0e83347d
shambo001/peat
Ghost/EM_effect.py
[ "MIT" ]
Python
enable_group_editing
<not_specific>
def enable_group_editing(self,event): """Enable editing of the properties of a group""" group_num=int(self.LB_added_groups.curselection()[0]) selected_group=self.selected_groups[group_num][0] # # def get_new_colour(): import tkColorChooser rgb,colo...
Enable editing of the properties of a group
Enable editing of the properties of a group
[ "Enable", "editing", "of", "the", "properties", "of", "a", "group" ]
def enable_group_editing(self,event): group_num=int(self.LB_added_groups.curselection()[0]) selected_group=self.selected_groups[group_num][0] def get_new_colour(): import tkColorChooser rgb,colorstring=tkColorChooser.askcolor(self.group_properties[selected_group]['colour'...
[ "def", "enable_group_editing", "(", "self", ",", "event", ")", ":", "group_num", "=", "int", "(", "self", ".", "LB_added_groups", ".", "curselection", "(", ")", "[", "0", "]", ")", "selected_group", "=", "self", ".", "selected_groups", "[", "group_num", "]...
Enable editing of the properties of a group
[ "Enable", "editing", "of", "the", "properties", "of", "a", "group" ]
[ "\"\"\"Enable editing of the properties of a group\"\"\"", "#", "#", "\"\"\"Update teh dielectric constant for a calc\"\"\"", "#", "# Display checkbutton", "#", "#", "# Elecalc button", "#" ]
[ { "param": "self", "type": null }, { "param": "event", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "event", "type": null, "docstring": null, "docstring_tokens": ...
c19178b82aed4697ad34f77c541ab11a0e83347d
shambo001/peat
Ghost/EM_effect.py
[ "MIT" ]
Python
update_diel
<not_specific>
def update_diel(event=None): """Update teh dielectric constant for a calc""" diel=self.diel_var.get() self.group_properties[selected_group]['diel']=diel self.update_EM_effect_prediction() return
Update teh dielectric constant for a calc
Update teh dielectric constant for a calc
[ "Update", "teh", "dielectric", "constant", "for", "a", "calc" ]
def update_diel(event=None): diel=self.diel_var.get() self.group_properties[selected_group]['diel']=diel self.update_EM_effect_prediction() return
[ "def", "update_diel", "(", "event", "=", "None", ")", ":", "diel", "=", "self", ".", "diel_var", ".", "get", "(", ")", "self", ".", "group_properties", "[", "selected_group", "]", "[", "'diel'", "]", "=", "diel", "self", ".", "update_EM_effect_prediction",...
Update teh dielectric constant for a calc
[ "Update", "teh", "dielectric", "constant", "for", "a", "calc" ]
[ "\"\"\"Update teh dielectric constant for a calc\"\"\"" ]
[ { "param": "event", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "event", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
c19178b82aed4697ad34f77c541ab11a0e83347d
shambo001/peat
Ghost/EM_effect.py
[ "MIT" ]
Python
load_pdb
<not_specific>
def load_pdb(self,filename=None): """Load a PDB file and build all the HNs""" import tkFileDialog, os if hasattr(self,'savedir'): savedir=self.savedir else: savedir=os.getcwd() if not filename: filename=tkFileDialog.askopenfilename(defaultexten...
Load a PDB file and build all the HNs
Load a PDB file and build all the HNs
[ "Load", "a", "PDB", "file", "and", "build", "all", "the", "HNs" ]
def load_pdb(self,filename=None): import tkFileDialog, os if hasattr(self,'savedir'): savedir=self.savedir else: savedir=os.getcwd() if not filename: filename=tkFileDialog.askopenfilename(defaultextension="*.pdb", ...
[ "def", "load_pdb", "(", "self", ",", "filename", "=", "None", ")", ":", "import", "tkFileDialog", ",", "os", "if", "hasattr", "(", "self", ",", "'savedir'", ")", ":", "savedir", "=", "self", ".", "savedir", "else", ":", "savedir", "=", "os", ".", "ge...
Load a PDB file and build all the HNs
[ "Load", "a", "PDB", "file", "and", "build", "all", "the", "HNs" ]
[ "\"\"\"Load a PDB file and build all the HNs\"\"\"", "#", "# Build all HNs", "#", "#", "# Count protein residues", "#", "#", "# Redraw the canvas", "#", "#", "# Get the titratable groups", "#", "#", "# If we are started from yasara then load the pdb file", "#" ]
[ { "param": "self", "type": null }, { "param": "filename", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "filename", "type": null, "docstring": null, "docstring_tokens...
c19178b82aed4697ad34f77c541ab11a0e83347d
shambo001/peat
Ghost/EM_effect.py
[ "MIT" ]
Python
def_titgrp
<not_specific>
def def_titgrp(self): """Define a titratable group There are two steps 1. Define the position 2. Define the titrational behaviour """ self.seldef_win=Toplevel() self.set_geometry(self.master,self.seldef_win) self.seldef_win.title('Select/Define ti...
Define a titratable group There are two steps 1. Define the position 2. Define the titrational behaviour
Define a titratable group There are two steps 1. Define the position 2. Define the titrational behaviour
[ "Define", "a", "titratable", "group", "There", "are", "two", "steps", "1", ".", "Define", "the", "position", "2", ".", "Define", "the", "titrational", "behaviour" ]
def def_titgrp(self): self.seldef_win=Toplevel() self.set_geometry(self.master,self.seldef_win) self.seldef_win.title('Select/Define titratable group') Label(self.seldef_win,text='Titratable group').grid(row=1,column=0) Button(self.seldef_win,text='Select from PDB file',command=s...
[ "def", "def_titgrp", "(", "self", ")", ":", "self", ".", "seldef_win", "=", "Toplevel", "(", ")", "self", ".", "set_geometry", "(", "self", ".", "master", ",", "self", ".", "seldef_win", ")", "self", ".", "seldef_win", ".", "title", "(", "'Select/Define ...
Define a titratable group There are two steps 1.
[ "Define", "a", "titratable", "group", "There", "are", "two", "steps", "1", "." ]
[ "\"\"\"Define a titratable group\n There are two steps\n 1. Define the position\n 2. Define the titrational behaviour\n \n \"\"\"", "#", "# Titration behaviour", "#", "#", "# Nitrogen or Hydrogen chemical shift", "#", "#", "# Add group button", "#", "#", "# A...
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
c19178b82aed4697ad34f77c541ab11a0e83347d
shambo001/peat
Ghost/EM_effect.py
[ "MIT" ]
Python
select_titgrp_frompdb
<not_specific>
def select_titgrp_frompdb(self,window=None): """Select a titratable group from the PDB file""" # # We can do this in any window # if not window: window=self.seldef_win # # Make the dialog # titgrps=self.PI.titratable_groups.keys() ...
Select a titratable group from the PDB file
Select a titratable group from the PDB file
[ "Select", "a", "titratable", "group", "from", "the", "PDB", "file" ]
def select_titgrp_frompdb(self,window=None): We can do this in any window if not window: window=self.seldef_win Make the dialog titgrps=self.PI.titratable_groups.keys() titgrps.sort() self.titgroups_inPDB=[] for res in titgrps: for titgrp...
[ "def", "select_titgrp_frompdb", "(", "self", ",", "window", "=", "None", ")", ":", "if", "not", "window", ":", "window", "=", "self", ".", "seldef_win", "titgrps", "=", "self", ".", "PI", ".", "titratable_groups", ".", "keys", "(", ")", "titgrps", ".", ...
Select a titratable group from the PDB file
[ "Select", "a", "titratable", "group", "from", "the", "PDB", "file" ]
[ "\"\"\"Select a titratable group from the PDB file\"\"\"", "#", "# We can do this in any window", "#", "#", "# Make the dialog", "#", "#" ]
[ { "param": "self", "type": null }, { "param": "window", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "window", "type": null, "docstring": null, "docstring_tokens":...
c19178b82aed4697ad34f77c541ab11a0e83347d
shambo001/peat
Ghost/EM_effect.py
[ "MIT" ]
Python
update_EM_effect_prediction
<not_specific>
def update_EM_effect_prediction(self,do_yasara=None): """Recalculate all EM effects and redraw all""" # # Should we recolour yasara? # if self.yasara and do_yasara: do_yasara=True # # First delete the bars from last time # if not hasatt...
Recalculate all EM effects and redraw all
Recalculate all EM effects and redraw all
[ "Recalculate", "all", "EM", "effects", "and", "redraw", "all" ]
def update_EM_effect_prediction(self,do_yasara=None): Should we recolour yasara? if self.yasara and do_yasara: do_yasara=True First delete the bars from last time if not hasattr(self,'graph_bars'): self.graph_bars={} for bar in self.graph_bars.keys(): ...
[ "def", "update_EM_effect_prediction", "(", "self", ",", "do_yasara", "=", "None", ")", ":", "if", "self", ".", "yasara", "and", "do_yasara", ":", "do_yasara", "=", "True", "if", "not", "hasattr", "(", "self", ",", "'graph_bars'", ")", ":", "self", ".", "...
Recalculate all EM effects and redraw all
[ "Recalculate", "all", "EM", "effects", "and", "redraw", "all" ]
[ "\"\"\"Recalculate all EM effects and redraw all\"\"\"", "#", "# Should we recolour yasara?", "#", "#", "# First delete the bars from last time", "#", "#", "# Loop over all groups we're looking at", "#", "#", "# Get the coordinate center of the charge that it titrating", "#", "#", "# Get...
[ { "param": "self", "type": null }, { "param": "do_yasara", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "do_yasara", "type": null, "docstring": null, "docstring_token...
c19178b82aed4697ad34f77c541ab11a0e83347d
shambo001/peat
Ghost/EM_effect.py
[ "MIT" ]
Python
print_chemshift_to_file
<not_specific>
def print_chemshift_to_file(self): """Print the chemical shift canvas to file""" import sys, os import tkFileDialog, os if not hasattr(self,'lastdir'): self.lastdir=os.getcwd() filename=tkFileDialog.asksaveasfilename(defaultextension='.ps', ...
Print the chemical shift canvas to file
Print the chemical shift canvas to file
[ "Print", "the", "chemical", "shift", "canvas", "to", "file" ]
def print_chemshift_to_file(self): import sys, os import tkFileDialog, os if not hasattr(self,'lastdir'): self.lastdir=os.getcwd() filename=tkFileDialog.asksaveasfilename(defaultextension='.ps', initialdir=self.lastdir, ...
[ "def", "print_chemshift_to_file", "(", "self", ")", ":", "import", "sys", ",", "os", "import", "tkFileDialog", ",", "os", "if", "not", "hasattr", "(", "self", ",", "'lastdir'", ")", ":", "self", ".", "lastdir", "=", "os", ".", "getcwd", "(", ")", "file...
Print the chemical shift canvas to file
[ "Print", "the", "chemical", "shift", "canvas", "to", "file" ]
[ "\"\"\"Print the chemical shift canvas to file\"\"\"" ]
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
c19178b82aed4697ad34f77c541ab11a0e83347d
shambo001/peat
Ghost/EM_effect.py
[ "MIT" ]
Python
load_csv
<not_specific>
def load_csv(self,filename=None,group=None): """Open a file with chem shift data""" self.exp_group_selected=group # # Make sure we have the expdata array # if not hasattr(self,'expdata'): self.expdata={} # # Load data # ...
Open a file with chem shift data
Open a file with chem shift data
[ "Open", "a", "file", "with", "chem", "shift", "data" ]
def load_csv(self,filename=None,group=None): self.exp_group_selected=group Make sure we have the expdata array if not hasattr(self,'expdata'): self.expdata={} Load data import tkFileDialog, os savedir=os.getcwd() if not filename: filename...
[ "def", "load_csv", "(", "self", ",", "filename", "=", "None", ",", "group", "=", "None", ")", ":", "self", ".", "exp_group_selected", "=", "group", "if", "not", "hasattr", "(", "self", ",", "'expdata'", ")", ":", "self", ".", "expdata", "=", "{", "}"...
Open a file with chem shift data
[ "Open", "a", "file", "with", "chem", "shift", "data" ]
[ "\"\"\"Open a file with chem shift data\"\"\"", "#", "# Make sure we have the expdata array", "#", "#", "# Load data", "#", "#", "# Ask which titratable group the data should be associated with", "#", "#", "# Read the data", "#", "#", "# Add it to the listbox", "#" ]
[ { "param": "self", "type": null }, { "param": "filename", "type": null }, { "param": "group", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "filename", "type": null, "docstring": null, "docstring_tokens...
c19178b82aed4697ad34f77c541ab11a0e83347d
shambo001/peat
Ghost/EM_effect.py
[ "MIT" ]
Python
load_full_titdata
<not_specific>
def load_full_titdata(self,filename=None,pH_start=5.2,pH_end=7.2): """Load a full set of titration data from en Ekin project file""" import full_titfit self.fullfit=full_titfit.titfitter(filename,pH_start,pH_end) return
Load a full set of titration data from en Ekin project file
Load a full set of titration data from en Ekin project file
[ "Load", "a", "full", "set", "of", "titration", "data", "from", "en", "Ekin", "project", "file" ]
def load_full_titdata(self,filename=None,pH_start=5.2,pH_end=7.2): import full_titfit self.fullfit=full_titfit.titfitter(filename,pH_start,pH_end) return
[ "def", "load_full_titdata", "(", "self", ",", "filename", "=", "None", ",", "pH_start", "=", "5.2", ",", "pH_end", "=", "7.2", ")", ":", "import", "full_titfit", "self", ".", "fullfit", "=", "full_titfit", ".", "titfitter", "(", "filename", ",", "pH_start"...
Load a full set of titration data from en Ekin project file
[ "Load", "a", "full", "set", "of", "titration", "data", "from", "en", "Ekin", "project", "file" ]
[ "\"\"\"Load a full set of titration data from en Ekin project file\"\"\"" ]
[ { "param": "self", "type": null }, { "param": "filename", "type": null }, { "param": "pH_start", "type": null }, { "param": "pH_end", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "filename", "type": null, "docstring": null, "docstring_tokens...
0d2ef155cf1dbd8ac38122a02a610e5298878842
shambo001/peat
DNATool2/DNAToolApp.py
[ "MIT" ]
Python
loadPrefs
<not_specific>
def loadPrefs(self): """Load prefs from a preferences instance""" self.preferences = Preferences('DNATool2',{}) temp = {} for key in self.defaultprefs: if not key in self.preferences.prefs: self.preferences.set(key, self.defaultprefs[key]) temp[key...
Load prefs from a preferences instance
Load prefs from a preferences instance
[ "Load", "prefs", "from", "a", "preferences", "instance" ]
def loadPrefs(self): self.preferences = Preferences('DNATool2',{}) temp = {} for key in self.defaultprefs: if not key in self.preferences.prefs: self.preferences.set(key, self.defaultprefs[key]) temp[key] = self.preferences.get(key) self.applyPrefs...
[ "def", "loadPrefs", "(", "self", ")", ":", "self", ".", "preferences", "=", "Preferences", "(", "'DNATool2'", ",", "{", "}", ")", "temp", "=", "{", "}", "for", "key", "in", "self", ".", "defaultprefs", ":", "if", "not", "key", "in", "self", ".", "p...
Load prefs from a preferences instance
[ "Load", "prefs", "from", "a", "preferences", "instance" ]
[ "\"\"\"Load prefs from a preferences instance\"\"\"" ]
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
0d2ef155cf1dbd8ac38122a02a610e5298878842
shambo001/peat
DNATool2/DNAToolApp.py
[ "MIT" ]
Python
savePrefs
<not_specific>
def savePrefs(self): """Save prefs to a preferences instance""" self.applyPrefs(self.prefsdialog.getValues()) self.preferences = Preferences('DNATool2',{}) for key in self.defaultprefs: self.preferences.set(key, self.__dict__[key]) return
Save prefs to a preferences instance
Save prefs to a preferences instance
[ "Save", "prefs", "to", "a", "preferences", "instance" ]
def savePrefs(self): self.applyPrefs(self.prefsdialog.getValues()) self.preferences = Preferences('DNATool2',{}) for key in self.defaultprefs: self.preferences.set(key, self.__dict__[key]) return
[ "def", "savePrefs", "(", "self", ")", ":", "self", ".", "applyPrefs", "(", "self", ".", "prefsdialog", ".", "getValues", "(", ")", ")", "self", ".", "preferences", "=", "Preferences", "(", "'DNATool2'", ",", "{", "}", ")", "for", "key", "in", "self", ...
Save prefs to a preferences instance
[ "Save", "prefs", "to", "a", "preferences", "instance" ]
[ "\"\"\"Save prefs to a preferences instance\"\"\"" ]
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
0d2ef155cf1dbd8ac38122a02a610e5298878842
shambo001/peat
DNATool2/DNAToolApp.py
[ "MIT" ]
Python
applyPrefs
<not_specific>
def applyPrefs(self, prefs=None): """Apply prefs from a given dict""" if prefs == None: prefs=self.defaultprefs for key in prefs: self.__dict__[key] = prefs[key] return
Apply prefs from a given dict
Apply prefs from a given dict
[ "Apply", "prefs", "from", "a", "given", "dict" ]
def applyPrefs(self, prefs=None): if prefs == None: prefs=self.defaultprefs for key in prefs: self.__dict__[key] = prefs[key] return
[ "def", "applyPrefs", "(", "self", ",", "prefs", "=", "None", ")", ":", "if", "prefs", "==", "None", ":", "prefs", "=", "self", ".", "defaultprefs", "for", "key", "in", "prefs", ":", "self", ".", "__dict__", "[", "key", "]", "=", "prefs", "[", "key"...
Apply prefs from a given dict
[ "Apply", "prefs", "from", "a", "given", "dict" ]
[ "\"\"\"Apply prefs from a given dict\"\"\"" ]
[ { "param": "self", "type": null }, { "param": "prefs", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "prefs", "type": null, "docstring": null, "docstring_tokens": ...
0d2ef155cf1dbd8ac38122a02a610e5298878842
shambo001/peat
DNATool2/DNAToolApp.py
[ "MIT" ]
Python
createMenuBar
<not_specific>
def createMenuBar(self): """Create the menu bar for the application. """ self.menu=Menu(self.main) self.file_menu={'01Open Project':{'cmd':self.openProject}, '02Open Sequence':{'cmd':self.openSequence}, '05Quit':{'cmd':self.quit}} self.file...
Create the menu bar for the application.
Create the menu bar for the application.
[ "Create", "the", "menu", "bar", "for", "the", "application", "." ]
def createMenuBar(self): self.menu=Menu(self.main) self.file_menu={'01Open Project':{'cmd':self.openProject}, '02Open Sequence':{'cmd':self.openSequence}, '05Quit':{'cmd':self.quit}} self.file_menu=self.create_pulldown(self.menu,self.file_menu) ...
[ "def", "createMenuBar", "(", "self", ")", ":", "self", ".", "menu", "=", "Menu", "(", "self", ".", "main", ")", "self", ".", "file_menu", "=", "{", "'01Open Project'", ":", "{", "'cmd'", ":", "self", ".", "openProject", "}", ",", "'02Open Sequence'", "...
Create the menu bar for the application.
[ "Create", "the", "menu", "bar", "for", "the", "application", "." ]
[ "\"\"\"Create the menu bar for the application. \"\"\"" ]
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
0d2ef155cf1dbd8ac38122a02a610e5298878842
shambo001/peat
DNATool2/DNAToolApp.py
[ "MIT" ]
Python
createSidePane
<not_specific>
def createSidePane(self, width=200): """Side panel for various dialogs is tabbed notebook that can hold multiple dialogs at once """ self.closeSidePane() self.sidepane = Frame(self.m, bd=1,relief=RAISED) self.sidepane = Pmw.NoteBook(self.m) ...
Side panel for various dialogs is tabbed notebook that can hold multiple dialogs at once
Side panel for various dialogs is tabbed notebook that can hold multiple dialogs at once
[ "Side", "panel", "for", "various", "dialogs", "is", "tabbed", "notebook", "that", "can", "hold", "multiple", "dialogs", "at", "once" ]
def createSidePane(self, width=200): self.closeSidePane() self.sidepane = Frame(self.m, bd=1,relief=RAISED) self.sidepane = Pmw.NoteBook(self.m) self.sidepane.component('hull').configure(relief='sunken', bo...
[ "def", "createSidePane", "(", "self", ",", "width", "=", "200", ")", ":", "self", ".", "closeSidePane", "(", ")", "self", ".", "sidepane", "=", "Frame", "(", "self", ".", "m", ",", "bd", "=", "1", ",", "relief", "=", "RAISED", ")", "self", ".", "...
Side panel for various dialogs is tabbed notebook that can hold multiple dialogs at once
[ "Side", "panel", "for", "various", "dialogs", "is", "tabbed", "notebook", "that", "can", "hold", "multiple", "dialogs", "at", "once" ]
[ "\"\"\"Side panel for various dialogs is tabbed notebook that can hold multiple\n dialogs at once \"\"\"" ]
[ { "param": "self", "type": null }, { "param": "width", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "width", "type": null, "docstring": null, "docstring_tokens": ...
0d2ef155cf1dbd8ac38122a02a610e5298878842
shambo001/peat
DNATool2/DNAToolApp.py
[ "MIT" ]
Python
createChildFrame
<not_specific>
def createChildFrame(self, sidepane=True, width=400, name=None): """Create a child frame in sidepane notebook or as toplevel""" geometry = '600x400+500+250' if sidepane == True: cframe = self.sidepane.add(name) self.sidepane.tab(name).configure(font='fixed 8',anchor='w') ...
Create a child frame in sidepane notebook or as toplevel
Create a child frame in sidepane notebook or as toplevel
[ "Create", "a", "child", "frame", "in", "sidepane", "notebook", "or", "as", "toplevel" ]
def createChildFrame(self, sidepane=True, width=400, name=None): geometry = '600x400+500+250' if sidepane == True: cframe = self.sidepane.add(name) self.sidepane.tab(name).configure(font='fixed 8',anchor='w') self.sidepane.selectpage(name) else: cf...
[ "def", "createChildFrame", "(", "self", ",", "sidepane", "=", "True", ",", "width", "=", "400", ",", "name", "=", "None", ")", ":", "geometry", "=", "'600x400+500+250'", "if", "sidepane", "==", "True", ":", "cframe", "=", "self", ".", "sidepane", ".", ...
Create a child frame in sidepane notebook or as toplevel
[ "Create", "a", "child", "frame", "in", "sidepane", "notebook", "or", "as", "toplevel" ]
[ "\"\"\"Create a child frame in sidepane notebook or as toplevel\"\"\"", "#if name is a pre-defined app we load fetch the class", "#bind frame close" ]
[ { "param": "self", "type": null }, { "param": "sidepane", "type": null }, { "param": "width", "type": null }, { "param": "name", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "sidepane", "type": null, "docstring": null, "docstring_tokens...
0d2ef155cf1dbd8ac38122a02a610e5298878842
shambo001/peat
DNATool2/DNAToolApp.py
[ "MIT" ]
Python
detachChildFrame
<not_specific>
def detachChildFrame(self): """Since we cannot actually detach frames in Tkinter, we remove the frame in the sidepane make a new toplevel window""" name = self.sidepane.getcurselection() self.sidepane.delete(name) if name == 'PrimerDB': fr = self.createPrimerDBGUI(...
Since we cannot actually detach frames in Tkinter, we remove the frame in the sidepane make a new toplevel window
Since we cannot actually detach frames in Tkinter, we remove the frame in the sidepane make a new toplevel window
[ "Since", "we", "cannot", "actually", "detach", "frames", "in", "Tkinter", "we", "remove", "the", "frame", "in", "the", "sidepane", "make", "a", "new", "toplevel", "window" ]
def detachChildFrame(self): name = self.sidepane.getcurselection() self.sidepane.delete(name) if name == 'PrimerDB': fr = self.createPrimerDBGUI(sidepane=False) else: fr = self.createChildFrame(sidepane=False, name=name) return fr
[ "def", "detachChildFrame", "(", "self", ")", ":", "name", "=", "self", ".", "sidepane", ".", "getcurselection", "(", ")", "self", ".", "sidepane", ".", "delete", "(", "name", ")", "if", "name", "==", "'PrimerDB'", ":", "fr", "=", "self", ".", "createPr...
Since we cannot actually detach frames in Tkinter, we remove the frame in the sidepane make a new toplevel window
[ "Since", "we", "cannot", "actually", "detach", "frames", "in", "Tkinter", "we", "remove", "the", "frame", "in", "the", "sidepane", "make", "a", "new", "toplevel", "window" ]
[ "\"\"\"Since we cannot actually detach frames in Tkinter, we\n remove the frame in the sidepane make a new toplevel window\"\"\"" ]
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
0d2ef155cf1dbd8ac38122a02a610e5298878842
shambo001/peat
DNATool2/DNAToolApp.py
[ "MIT" ]
Python
toggleApps
<not_specific>
def toggleApps(self, name): """Remove or add apps from view""" print name if self.appsvars[name].get() == 1: if not hasattr(self, name): fr = self.createChildFrame(sidepane=True, name=name) else: if hasattr(self, name): if name in s...
Remove or add apps from view
Remove or add apps from view
[ "Remove", "or", "add", "apps", "from", "view" ]
def toggleApps(self, name): print name if self.appsvars[name].get() == 1: if not hasattr(self, name): fr = self.createChildFrame(sidepane=True, name=name) else: if hasattr(self, name): if name in self.sidepane.pagenames(): ...
[ "def", "toggleApps", "(", "self", ",", "name", ")", ":", "print", "name", "if", "self", ".", "appsvars", "[", "name", "]", ".", "get", "(", ")", "==", "1", ":", "if", "not", "hasattr", "(", "self", ",", "name", ")", ":", "fr", "=", "self", ".",...
Remove or add apps from view
[ "Remove", "or", "add", "apps", "from", "view" ]
[ "\"\"\"Remove or add apps from view\"\"\"" ]
[ { "param": "self", "type": null }, { "param": "name", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "name", "type": null, "docstring": null, "docstring_tokens": [...
0d2ef155cf1dbd8ac38122a02a610e5298878842
shambo001/peat
DNATool2/DNAToolApp.py
[ "MIT" ]
Python
tileHorizontal
<not_specific>
def tileHorizontal(self): """Re-arrange paned widgets horizontally""" if self.orientation == 'horizontal': return self.removeAll() self.orientation = 'horizontal' self.setupGUI() return
Re-arrange paned widgets horizontally
Re-arrange paned widgets horizontally
[ "Re", "-", "arrange", "paned", "widgets", "horizontally" ]
def tileHorizontal(self): if self.orientation == 'horizontal': return self.removeAll() self.orientation = 'horizontal' self.setupGUI() return
[ "def", "tileHorizontal", "(", "self", ")", ":", "if", "self", ".", "orientation", "==", "'horizontal'", ":", "return", "self", ".", "removeAll", "(", ")", "self", ".", "orientation", "=", "'horizontal'", "self", ".", "setupGUI", "(", ")", "return" ]
Re-arrange paned widgets horizontally
[ "Re", "-", "arrange", "paned", "widgets", "horizontally" ]
[ "\"\"\"Re-arrange paned widgets horizontally\"\"\"" ]
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
0d2ef155cf1dbd8ac38122a02a610e5298878842
shambo001/peat
DNATool2/DNAToolApp.py
[ "MIT" ]
Python
tileVertical
<not_specific>
def tileVertical(self): """Re-arrange paned widgets vertically""" if self.orientation == 'vertical': return self.removeAll() self.orientation = 'vertical' self.setupGUI() return
Re-arrange paned widgets vertically
Re-arrange paned widgets vertically
[ "Re", "-", "arrange", "paned", "widgets", "vertically" ]
def tileVertical(self): if self.orientation == 'vertical': return self.removeAll() self.orientation = 'vertical' self.setupGUI() return
[ "def", "tileVertical", "(", "self", ")", ":", "if", "self", ".", "orientation", "==", "'vertical'", ":", "return", "self", ".", "removeAll", "(", ")", "self", ".", "orientation", "=", "'vertical'", "self", ".", "setupGUI", "(", ")", "return" ]
Re-arrange paned widgets vertically
[ "Re", "-", "arrange", "paned", "widgets", "vertically" ]
[ "\"\"\"Re-arrange paned widgets vertically\"\"\"" ]
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
0d2ef155cf1dbd8ac38122a02a610e5298878842
shambo001/peat
DNATool2/DNAToolApp.py
[ "MIT" ]
Python
createPrimerDBGUI
<not_specific>
def createPrimerDBGUI(self, sidepane=True): """We create this individually to avoid confusion""" if hasattr(self, 'PrimerDB'): self.PrimerDB.lift() return fr = self.createChildFrame(name='PrimerDB',sidepane=sidepane) self.pdbwin = PrimerDBGUI(fr, database=self.pri...
We create this individually to avoid confusion
We create this individually to avoid confusion
[ "We", "create", "this", "individually", "to", "avoid", "confusion" ]
def createPrimerDBGUI(self, sidepane=True): if hasattr(self, 'PrimerDB'): self.PrimerDB.lift() return fr = self.createChildFrame(name='PrimerDB',sidepane=sidepane) self.pdbwin = PrimerDBGUI(fr, database=self.primerdb) self.pdbwin.update() self.pdbwin.pack(...
[ "def", "createPrimerDBGUI", "(", "self", ",", "sidepane", "=", "True", ")", ":", "if", "hasattr", "(", "self", ",", "'PrimerDB'", ")", ":", "self", ".", "PrimerDB", ".", "lift", "(", ")", "return", "fr", "=", "self", ".", "createChildFrame", "(", "name...
We create this individually to avoid confusion
[ "We", "create", "this", "individually", "to", "avoid", "confusion" ]
[ "\"\"\"We create this individually to avoid confusion\"\"\"", "#bind window closing so it's automatically recreated in the sidepane" ]
[ { "param": "self", "type": null }, { "param": "sidepane", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "sidepane", "type": null, "docstring": null, "docstring_tokens...
d2c16c3cc5d636f9743c2e2b0b87f18e4375fcea
shambo001/peat
PEATDB/plugins/titranalysis.py
[ "MIT" ]
Python
createMenuBar
<not_specific>
def createMenuBar(self): """Create the menu bar for the application. """ self.menu=Menu(self.mainwin) self.file_menu={ '01Open Ekin project':{'cmd':self.loadEkinProj}, '02Open DB':{'cmd':self.openDB}, '03Quit':{'cmd':self.quit}} self.fil...
Create the menu bar for the application.
Create the menu bar for the application.
[ "Create", "the", "menu", "bar", "for", "the", "application", "." ]
def createMenuBar(self): self.menu=Menu(self.mainwin) self.file_menu={ '01Open Ekin project':{'cmd':self.loadEkinProj}, '02Open DB':{'cmd':self.openDB}, '03Quit':{'cmd':self.quit}} self.file_menu=self.create_pulldown(self.menu,self.file_menu) ...
[ "def", "createMenuBar", "(", "self", ")", ":", "self", ".", "menu", "=", "Menu", "(", "self", ".", "mainwin", ")", "self", ".", "file_menu", "=", "{", "'01Open Ekin project'", ":", "{", "'cmd'", ":", "self", ".", "loadEkinProj", "}", ",", "'02Open DB'", ...
Create the menu bar for the application.
[ "Create", "the", "menu", "bar", "for", "the", "application", "." ]
[ "\"\"\"Create the menu bar for the application. \"\"\"" ]
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
d2c16c3cc5d636f9743c2e2b0b87f18e4375fcea
shambo001/peat
PEATDB/plugins/titranalysis.py
[ "MIT" ]
Python
selectfromDB
<not_specific>
def selectfromDB(self): """Get an ekin prj from the DB""" if self.DB == None: return from PEATDB.Actions import DBActions fr=Toplevel() rbox, cbox = DBActions.getRecordsSelector(self.DB,fr) def loadselected(): item = rbox.curselection()[0] ...
Get an ekin prj from the DB
Get an ekin prj from the DB
[ "Get", "an", "ekin", "prj", "from", "the", "DB" ]
def selectfromDB(self): if self.DB == None: return from PEATDB.Actions import DBActions fr=Toplevel() rbox, cbox = DBActions.getRecordsSelector(self.DB,fr) def loadselected(): item = rbox.curselection()[0] rec = self.DB.getRecs()[int(item)] ...
[ "def", "selectfromDB", "(", "self", ")", ":", "if", "self", ".", "DB", "==", "None", ":", "return", "from", "PEATDB", ".", "Actions", "import", "DBActions", "fr", "=", "Toplevel", "(", ")", "rbox", ",", "cbox", "=", "DBActions", ".", "getRecordsSelector"...
Get an ekin prj from the DB
[ "Get", "an", "ekin", "prj", "from", "the", "DB" ]
[ "\"\"\"Get an ekin prj from the DB\"\"\"" ]
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
d2c16c3cc5d636f9743c2e2b0b87f18e4375fcea
shambo001/peat
PEATDB/plugins/titranalysis.py
[ "MIT" ]
Python
showEkinTable
<not_specific>
def showEkinTable(self, parent, E=None): """Show a list of ekin prj datasets in a table""" self.currentmodel = EkinProjModel(E) fr=Frame(parent) self.pw.add(fr,minsize=200) self.ekintable = EkinProjTable(fr, self.currentmodel) self.ekintable.createTableFrame() ret...
Show a list of ekin prj datasets in a table
Show a list of ekin prj datasets in a table
[ "Show", "a", "list", "of", "ekin", "prj", "datasets", "in", "a", "table" ]
def showEkinTable(self, parent, E=None): self.currentmodel = EkinProjModel(E) fr=Frame(parent) self.pw.add(fr,minsize=200) self.ekintable = EkinProjTable(fr, self.currentmodel) self.ekintable.createTableFrame() return
[ "def", "showEkinTable", "(", "self", ",", "parent", ",", "E", "=", "None", ")", ":", "self", ".", "currentmodel", "=", "EkinProjModel", "(", "E", ")", "fr", "=", "Frame", "(", "parent", ")", "self", ".", "pw", ".", "add", "(", "fr", ",", "minsize",...
Show a list of ekin prj datasets in a table
[ "Show", "a", "list", "of", "ekin", "prj", "datasets", "in", "a", "table" ]
[ "\"\"\"Show a list of ekin prj datasets in a table\"\"\"" ]
[ { "param": "self", "type": null }, { "param": "parent", "type": null }, { "param": "E", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "parent", "type": null, "docstring": null, "docstring_tokens":...
d2c16c3cc5d636f9743c2e2b0b87f18e4375fcea
shambo001/peat
PEATDB/plugins/titranalysis.py
[ "MIT" ]
Python
analysepKas
<not_specific>
def analysepKas(self, p=None): """Get the main pKas of all/titr group and do analysis""" E = self.currprj if E==None: return t = TitrationAnalyser() if p == None: p = t.findpKas(E, titratable=True, reliable=False, minspan=0.06) t.analysepKas(p) return
Get the main pKas of all/titr group and do analysis
Get the main pKas of all/titr group and do analysis
[ "Get", "the", "main", "pKas", "of", "all", "/", "titr", "group", "and", "do", "analysis" ]
def analysepKas(self, p=None): E = self.currprj if E==None: return t = TitrationAnalyser() if p == None: p = t.findpKas(E, titratable=True, reliable=False, minspan=0.06) t.analysepKas(p) return
[ "def", "analysepKas", "(", "self", ",", "p", "=", "None", ")", ":", "E", "=", "self", ".", "currprj", "if", "E", "==", "None", ":", "return", "t", "=", "TitrationAnalyser", "(", ")", "if", "p", "==", "None", ":", "p", "=", "t", ".", "findpKas", ...
Get the main pKas of all/titr group and do analysis
[ "Get", "the", "main", "pKas", "of", "all", "/", "titr", "group", "and", "do", "analysis" ]
[ "\"\"\"Get the main pKas of all/titr group and do analysis\"\"\"" ]
[ { "param": "self", "type": null }, { "param": "p", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "p", "type": null, "docstring": null, "docstring_tokens": [], ...
d2c16c3cc5d636f9743c2e2b0b87f18e4375fcea
shambo001/peat
PEATDB/plugins/titranalysis.py
[ "MIT" ]
Python
titDBUtils
<not_specific>
def titDBUtils(self, DB=None, col=None, prot=None, a=None, E=None, refit=False, addmeta=False, getexperrs=False, yuncert=None): """Add some meta and refit all for an ekin prj or a rec/field in db""" if E==None and DB != None: E = DB[prot][col] ...
Add some meta and refit all for an ekin prj or a rec/field in db
Add some meta and refit all for an ekin prj or a rec/field in db
[ "Add", "some", "meta", "and", "refit", "all", "for", "an", "ekin", "prj", "or", "a", "rec", "/", "field", "in", "db" ]
def titDBUtils(self, DB=None, col=None, prot=None, a=None, E=None, refit=False, addmeta=False, getexperrs=False, yuncert=None): if E==None and DB != None: E = DB[prot][col] E.checkDatasets() t = TitrationAnalyser() if refit == True:...
[ "def", "titDBUtils", "(", "self", ",", "DB", "=", "None", ",", "col", "=", "None", ",", "prot", "=", "None", ",", "a", "=", "None", ",", "E", "=", "None", ",", "refit", "=", "False", ",", "addmeta", "=", "False", ",", "getexperrs", "=", "False", ...
Add some meta and refit all for an ekin prj or a rec/field in db
[ "Add", "some", "meta", "and", "refit", "all", "for", "an", "ekin", "prj", "or", "a", "rec", "/", "field", "in", "db" ]
[ "\"\"\"Add some meta and refit all for an ekin prj or a rec/field in db\"\"\"", "#DB.commit('refit/added meta info')" ]
[ { "param": "self", "type": null }, { "param": "DB", "type": null }, { "param": "col", "type": null }, { "param": "prot", "type": null }, { "param": "a", "type": null }, { "param": "E", "type": null }, { "param": "refit", "type": null ...
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "DB", "type": null, "docstring": null, "docstring_tokens": [],...
d2c16c3cc5d636f9743c2e2b0b87f18e4375fcea
shambo001/peat
PEATDB/plugins/titranalysis.py
[ "MIT" ]
Python
benchmarkExpErr
<not_specific>
def benchmarkExpErr(self, DB): """Test effects of model and noise on est exp error technique""" E = DB['HEWL']['1H NMR'] d='D66N-HN' E.plotDatasets(d,filename='experrtest.png') print E.getFitData(d) ferrs = E.estimateExpUncertainty(d, runs=20, xuncert=0.1,...
Test effects of model and noise on est exp error technique
Test effects of model and noise on est exp error technique
[ "Test", "effects", "of", "model", "and", "noise", "on", "est", "exp", "error", "technique" ]
def benchmarkExpErr(self, DB): E = DB['HEWL']['1H NMR'] d='D66N-HN' E.plotDatasets(d,filename='experrtest.png') print E.getFitData(d) ferrs = E.estimateExpUncertainty(d, runs=20, xuncert=0.1, yuncert=0.03) print ferrs return
[ "def", "benchmarkExpErr", "(", "self", ",", "DB", ")", ":", "E", "=", "DB", "[", "'HEWL'", "]", "[", "'1H NMR'", "]", "d", "=", "'D66N-HN'", "E", ".", "plotDatasets", "(", "d", ",", "filename", "=", "'experrtest.png'", ")", "print", "E", ".", "getFit...
Test effects of model and noise on est exp error technique
[ "Test", "effects", "of", "model", "and", "noise", "on", "est", "exp", "error", "technique" ]
[ "\"\"\"Test effects of model and noise on est exp error technique\"\"\"" ]
[ { "param": "self", "type": null }, { "param": "DB", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "DB", "type": null, "docstring": null, "docstring_tokens": [],...
d2c16c3cc5d636f9743c2e2b0b87f18e4375fcea
shambo001/peat
PEATDB/plugins/titranalysis.py
[ "MIT" ]
Python
addpKaTables
<not_specific>
def addpKaTables(self, DB, names, col='1H NMR'): """Create labbook tables for 'real' pKas for required proteins""" t = TitrationAnalyser() prots = t.getProtNames(DB) for name in names: recname = DB.getRecordName(name) E = DB[recname][col] titrresidues ...
Create labbook tables for 'real' pKas for required proteins
Create labbook tables for 'real' pKas for required proteins
[ "Create", "labbook", "tables", "for", "'", "real", "'", "pKas", "for", "required", "proteins" ]
def addpKaTables(self, DB, names, col='1H NMR'): t = TitrationAnalyser() prots = t.getProtNames(DB) for name in names: recname = DB.getRecordName(name) E = DB[recname][col] titrresidues = t.getResidues(E, titratable=True) S = DB.createLabbookSheet(...
[ "def", "addpKaTables", "(", "self", ",", "DB", ",", "names", ",", "col", "=", "'1H NMR'", ")", ":", "t", "=", "TitrationAnalyser", "(", ")", "prots", "=", "t", ".", "getProtNames", "(", "DB", ")", "for", "name", "in", "names", ":", "recname", "=", ...
Create labbook tables for 'real' pKas for required proteins
[ "Create", "labbook", "tables", "for", "'", "real", "'", "pKas", "for", "required", "proteins" ]
[ "\"\"\"Create labbook tables for 'real' pKas for required proteins\"\"\"" ]
[ { "param": "self", "type": null }, { "param": "DB", "type": null }, { "param": "names", "type": null }, { "param": "col", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "DB", "type": null, "docstring": null, "docstring_tokens": [],...
abd81230ee2d4ee092100b179d86320e78d7d53f
shambo001/peat
PEATDB/plugins/Summary.py
[ "MIT" ]
Python
populate
<not_specific>
def populate(self): """Clear the current data and populate with db data from dbs in projects dictionary""" print self.DB if self.DB == None: return for db in self.projects: recs = db.getRecs()
Clear the current data and populate with db data from dbs in projects dictionary
Clear the current data and populate with db data from dbs in projects dictionary
[ "Clear", "the", "current", "data", "and", "populate", "with", "db", "data", "from", "dbs", "in", "projects", "dictionary" ]
def populate(self): print self.DB if self.DB == None: return for db in self.projects: recs = db.getRecs()
[ "def", "populate", "(", "self", ")", ":", "print", "self", ".", "DB", "if", "self", ".", "DB", "==", "None", ":", "return", "for", "db", "in", "self", ".", "projects", ":", "recs", "=", "db", ".", "getRecs", "(", ")" ]
Clear the current data and populate with db data from dbs in projects dictionary
[ "Clear", "the", "current", "data", "and", "populate", "with", "db", "data", "from", "dbs", "in", "projects", "dictionary" ]
[ "\"\"\"Clear the current data and populate with db data\n from dbs in projects dictionary\"\"\"" ]
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
caaf0b255f1c38b405dfbe102920360f68120f16
shambo001/peat
Protool/Yasara_interface.py
[ "MIT" ]
Python
shortMD
<not_specific>
def shortMD(self,pdblines): """Do a short MD in vacou to get an ensemble""" objs=self.Y.BuildPDB(pdblines) self.Y.DelRes('WAT') self.Y.DelRes('HOH') self.Y.Clean() self.Y.CellAuto(extension=10) self.Y.ForceField('Amber99') self.Y.Boundary('Periodic') ...
Do a short MD in vacou to get an ensemble
Do a short MD in vacou to get an ensemble
[ "Do", "a", "short", "MD", "in", "vacou", "to", "get", "an", "ensemble" ]
def shortMD(self,pdblines): objs=self.Y.BuildPDB(pdblines) self.Y.DelRes('WAT') self.Y.DelRes('HOH') self.Y.Clean() self.Y.CellAuto(extension=10) self.Y.ForceField('Amber99') self.Y.Boundary('Periodic') self.Y.TempCtrl('SteepDes') self.Y.Sim('On') ...
[ "def", "shortMD", "(", "self", ",", "pdblines", ")", ":", "objs", "=", "self", ".", "Y", ".", "BuildPDB", "(", "pdblines", ")", "self", ".", "Y", ".", "DelRes", "(", "'WAT'", ")", "self", ".", "Y", ".", "DelRes", "(", "'HOH'", ")", "self", ".", ...
Do a short MD in vacou to get an ensemble
[ "Do", "a", "short", "MD", "in", "vacou", "to", "get", "an", "ensemble" ]
[ "\"\"\"Do a short MD in vacou to get an ensemble\"\"\"", "#self.Y.Temp(298.15,'Yes')" ]
[ { "param": "self", "type": null }, { "param": "pdblines", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "pdblines", "type": null, "docstring": null, "docstring_tokens...
3e47e3408abebefc99058533e086f4ade8ad3af6
shambo001/peat
pKaTool/Ghosts/Chemical_shift_md.py
[ "MIT" ]
Python
parseCharges
<not_specific>
def parseCharges(self): ''' Parse charges from the topology file ''' try: fd = open(self.top, 'r'); lines = fd.readlines() fd.close() except IOError: print '\n\t\tFATAL: Cannot open %s file'%self.top sys.exit(1) chargeDict = {} for lineNum in range(len(lines)): if lines[lineNum].strip() ...
Parse charges from the topology file
Parse charges from the topology file
[ "Parse", "charges", "from", "the", "topology", "file" ]
def parseCharges(self): try: fd = open(self.top, 'r'); lines = fd.readlines() fd.close() except IOError: print '\n\t\tFATAL: Cannot open %s file'%self.top sys.exit(1) chargeDict = {} for lineNum in range(len(lines)): if lines[lineNum].strip() == '[ atoms ]': for lineNum1 in range(lineNum+2...
[ "def", "parseCharges", "(", "self", ")", ":", "try", ":", "fd", "=", "open", "(", "self", ".", "top", ",", "'r'", ")", ";", "lines", "=", "fd", ".", "readlines", "(", ")", "fd", ".", "close", "(", ")", "except", "IOError", ":", "print", "'\\n\\t\...
Parse charges from the topology file
[ "Parse", "charges", "from", "the", "topology", "file" ]
[ "'''\n\t\tParse charges from the topology file\n\t\t'''" ]
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
3e47e3408abebefc99058533e086f4ade8ad3af6
shambo001/peat
pKaTool/Ghosts/Chemical_shift_md.py
[ "MIT" ]
Python
parseCoord
<not_specific>
def parseCoord(self, pdb): ''' Parse coordinates from the pdb file ''' try: fd = open(pdb, 'r'); lines = fd.readlines() fd.close() except: print '\n\t\tFATAL: Cannot open %s file'%pdb sys.exit(1) coordMol = {} coordSol = {} coordCl = {} for line in lines: record = line[:6].strip(...
Parse coordinates from the pdb file
Parse coordinates from the pdb file
[ "Parse", "coordinates", "from", "the", "pdb", "file" ]
def parseCoord(self, pdb): try: fd = open(pdb, 'r'); lines = fd.readlines() fd.close() except: print '\n\t\tFATAL: Cannot open %s file'%pdb sys.exit(1) coordMol = {} coordSol = {} coordCl = {} for line in lines: record = line[:6].strip() if record == 'ATOM': resNum = parseResNum(lin...
[ "def", "parseCoord", "(", "self", ",", "pdb", ")", ":", "try", ":", "fd", "=", "open", "(", "pdb", ",", "'r'", ")", ";", "lines", "=", "fd", ".", "readlines", "(", ")", "fd", ".", "close", "(", ")", "except", ":", "print", "'\\n\\t\\tFATAL: Cannot ...
Parse coordinates from the pdb file
[ "Parse", "coordinates", "from", "the", "pdb", "file" ]
[ "'''\n\t\tParse coordinates from the pdb file\n\t\t'''" ]
[ { "param": "self", "type": null }, { "param": "pdb", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "pdb", "type": null, "docstring": null, "docstring_tokens": []...
3e47e3408abebefc99058533e086f4ade8ad3af6
shambo001/peat
pKaTool/Ghosts/Chemical_shift_md.py
[ "MIT" ]
Python
calculateCSP
<not_specific>
def calculateCSP(self): ''' calculates potentials of all N, C (N and H) atoms from num1 and num2 side chains, protein, water and Cl ''' fd_progress = open("progress.log", 'a'); fileFirst = self.pdb + '.pdb.' + str(self.start) coordMol, coordSol, coordCl = self.parseCoord(fileFirst) resNumsMol = coordMo...
calculates potentials of all N, C (N and H) atoms from num1 and num2 side chains, protein, water and Cl
calculates potentials of all N, C (N and H) atoms from num1 and num2 side chains, protein, water and Cl
[ "calculates", "potentials", "of", "all", "N", "C", "(", "N", "and", "H", ")", "atoms", "from", "num1", "and", "num2", "side", "chains", "protein", "water", "and", "Cl" ]
def calculateCSP(self): fd_progress = open("progress.log", 'a'); fileFirst = self.pdb + '.pdb.' + str(self.start) coordMol, coordSol, coordCl = self.parseCoord(fileFirst) resNumsMol = coordMol.keys() resNumsMol.sort() resNumsSol = coordSol.keys() resNumsSol.sort() resNumsCl = coordCl.keys() resNumsCl....
[ "def", "calculateCSP", "(", "self", ")", ":", "fd_progress", "=", "open", "(", "\"progress.log\"", ",", "'a'", ")", ";", "fileFirst", "=", "self", ".", "pdb", "+", "'.pdb.'", "+", "str", "(", "self", ".", "start", ")", "coordMol", ",", "coordSol", ",",...
calculates potentials of all N, C (N and H) atoms from num1 and num2 side chains, protein, water and Cl
[ "calculates", "potentials", "of", "all", "N", "C", "(", "N", "and", "H", ")", "atoms", "from", "num1", "and", "num2", "side", "chains", "protein", "water", "and", "Cl" ]
[ "'''\n\t\tcalculates potentials of all N, C (N and H) atoms from num1 and num2 side chains, protein, water and Cl\n\t\t'''", "#PROLINE", "#N", "#does not include Cl", "#H", "#does not include Cl", "#too close to backbone atom", "#print resNum, atomName", "#if not atomName in chargeDict[resNum].keys(...
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
3e47e3408abebefc99058533e086f4ade8ad3af6
shambo001/peat
pKaTool/Ghosts/Chemical_shift_md.py
[ "MIT" ]
Python
plot
null
def plot(self): ''' Plot the outcome of the MD simulations ''' import matplotlib matplotlib.use('Agg') from mpl_toolkits.mplot3d import Axes3D import matplotlib.pyplot as plt from matplotlib import cm import numpy as np fileFirst = self.pdb + '.pdb.' + str(self.start) coordMol, coordSol, coordC...
Plot the outcome of the MD simulations
Plot the outcome of the MD simulations
[ "Plot", "the", "outcome", "of", "the", "MD", "simulations" ]
def plot(self): import matplotlib matplotlib.use('Agg') from mpl_toolkits.mplot3d import Axes3D import matplotlib.pyplot as plt from matplotlib import cm import numpy as np fileFirst = self.pdb + '.pdb.' + str(self.start) coordMol, coordSol, coordCl = self.parseCoord(fileFirst) resNumsMol = coordMol.k...
[ "def", "plot", "(", "self", ")", ":", "import", "matplotlib", "matplotlib", ".", "use", "(", "'Agg'", ")", "from", "mpl_toolkits", ".", "mplot3d", "import", "Axes3D", "import", "matplotlib", ".", "pyplot", "as", "plt", "from", "matplotlib", "import", "cm", ...
Plot the outcome of the MD simulations
[ "Plot", "the", "outcome", "of", "the", "MD", "simulations" ]
[ "'''\n\t\tPlot the outcome of the MD simulations\n\t\t'''", "#PROLINE", "#PROLINE", "# all the text.Text instance in the legend", "# all the lines.Line2D instance in the legend", "# the patch.Rectangle instance surrounding the legend", "# set the frame face color to light gray", "# set the alpha value...
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
b8840143c56d36dc7944c001646d41a0066171e4
shambo001/peat
PEATDB/DNAtool/DNA_sequencing.py
[ "MIT" ]
Python
show_DNAseq
<not_specific>
def show_DNAseq(self,seqfile=None,usecurrent=0,clearprev=1,level=0): """Load and display a sequence from a file""" if seqfile==None: seqfile = self.main_self.dnaseq_read(newprotein=None,variable='seq_comp',var2='seq_comp_file') # Pass the file to dnaseq_read instead of getting it to...
Load and display a sequence from a file
Load and display a sequence from a file
[ "Load", "and", "display", "a", "sequence", "from", "a", "file" ]
def show_DNAseq(self,seqfile=None,usecurrent=0,clearprev=1,level=0): if seqfile==None: seqfile = self.main_self.dnaseq_read(newprotein=None,variable='seq_comp',var2='seq_comp_file') else: self.main_self.dnaseq_read(newprotein=None,fileinput=seqfile,variable='seq_comp', ...
[ "def", "show_DNAseq", "(", "self", ",", "seqfile", "=", "None", ",", "usecurrent", "=", "0", ",", "clearprev", "=", "1", ",", "level", "=", "0", ")", ":", "if", "seqfile", "==", "None", ":", "seqfile", "=", "self", ".", "main_self", ".", "dnaseq_read...
Load and display a sequence from a file
[ "Load", "and", "display", "a", "sequence", "from", "a", "file" ]
[ "\"\"\"Load and display a sequence from a file\"\"\"", "# Pass the file to dnaseq_read instead of getting it to open a dialog", "#print 'seqfile:',seqfile", "#print self.main_self.data['seq_comp']", "# Clear previous seq first, this is default value in parameter list", "#print self.main_self.data['seq_com...
[ { "param": "self", "type": null }, { "param": "seqfile", "type": null }, { "param": "usecurrent", "type": null }, { "param": "clearprev", "type": null }, { "param": "level", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "seqfile", "type": null, "docstring": null, "docstring_tokens"...
b8840143c56d36dc7944c001646d41a0066171e4
shambo001/peat
PEATDB/DNAtool/DNA_sequencing.py
[ "MIT" ]
Python
show_multiple_DNAseq_dialog
<not_specific>
def show_multiple_DNAseq_dialog(self): """ This function provides a dialog to view and select the multiple loaded sequences """ self.choose_seq_win=Toplevel() self.choose_seq_win.title("Load Multiple DNA Sequences") #self.choose_seq_win.geometry("%dx%d%+d%+d" % (40, 20, 0...
This function provides a dialog to view and select the multiple loaded sequences
This function provides a dialog to view and select the multiple loaded sequences
[ "This", "function", "provides", "a", "dialog", "to", "view", "and", "select", "the", "multiple", "loaded", "sequences" ]
def show_multiple_DNAseq_dialog(self): self.choose_seq_win=Toplevel() self.choose_seq_win.title("Load Multiple DNA Sequences") self.choose_seq_win.geometry("+%d+%d" % (self.parent.master_win.winfo_rootx()+550, self.parent.master_win.winfo_rooty()+100)) O...
[ "def", "show_multiple_DNAseq_dialog", "(", "self", ")", ":", "self", ".", "choose_seq_win", "=", "Toplevel", "(", ")", "self", ".", "choose_seq_win", ".", "title", "(", "\"Load Multiple DNA Sequences\"", ")", "self", ".", "choose_seq_win", ".", "geometry", "(", ...
This function provides a dialog to view and select the multiple loaded sequences
[ "This", "function", "provides", "a", "dialog", "to", "view", "and", "select", "the", "multiple", "loaded", "sequences" ]
[ "\"\"\"\n This function provides a dialog to view and select the multiple loaded sequences\n \"\"\"", "#self.choose_seq_win.geometry(\"%dx%d%+d%+d\" % (40, 20, 0, 0))", "#do balloon help for buttons", "#self.details.bind(\"<Button-1>\",self.display_current)" ]
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
b8840143c56d36dc7944c001646d41a0066171e4
shambo001/peat
PEATDB/DNAtool/DNA_sequencing.py
[ "MIT" ]
Python
load_multiple
<not_specific>
def load_multiple(self,event=None): """load multiple files and show them in the details widget""" # a list with the current sequences loaded for display self.seq_list=[] self.seq_list_direction={} self.clear_list() # populate file list here self.seq_list = self.op...
load multiple files and show them in the details widget
load multiple files and show them in the details widget
[ "load", "multiple", "files", "and", "show", "them", "in", "the", "details", "widget" ]
def load_multiple(self,event=None): self.seq_list=[] self.seq_list_direction={} self.clear_list() self.seq_list = self.open_filelist() for name in self.seq_list: x = os.path.split(name) self.details.insert(END,x[1]) self.seq_list_dir...
[ "def", "load_multiple", "(", "self", ",", "event", "=", "None", ")", ":", "self", ".", "seq_list", "=", "[", "]", "self", ".", "seq_list_direction", "=", "{", "}", "self", ".", "clear_list", "(", ")", "self", ".", "seq_list", "=", "self", ".", "open_...
load multiple files and show them in the details widget
[ "load", "multiple", "files", "and", "show", "them", "in", "the", "details", "widget" ]
[ "\"\"\"load multiple files and show them in the details widget\"\"\"", "# a list with the current sequences loaded for display", "# populate file list here" ]
[ { "param": "self", "type": null }, { "param": "event", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "event", "type": null, "docstring": null, "docstring_tokens": ...
b8840143c56d36dc7944c001646d41a0066171e4
shambo001/peat
PEATDB/DNAtool/DNA_sequencing.py
[ "MIT" ]
Python
display_current
null
def display_current(self,event=None): """Display the current sequences selected in the listbox""" # Reset this if main window has been cleared while listbox open self.main_self.show_comp_sequence.set(1) self.main_self.maxseqlevel=0 self.main_self.seqframe.delete('strip') ...
Display the current sequences selected in the listbox
Display the current sequences selected in the listbox
[ "Display", "the", "current", "sequences", "selected", "in", "the", "listbox" ]
def display_current(self,event=None): self.main_self.show_comp_sequence.set(1) self.main_self.maxseqlevel=0 self.main_self.seqframe.delete('strip') tmp_sel = map(int, self.details.curselection()) p=0 if len(tmp_sel)==1: num=tmp_sel[0] self.show_DN...
[ "def", "display_current", "(", "self", ",", "event", "=", "None", ")", ":", "self", ".", "main_self", ".", "show_comp_sequence", ".", "set", "(", "1", ")", "self", ".", "main_self", ".", "maxseqlevel", "=", "0", "self", ".", "main_self", ".", "seqframe",...
Display the current sequences selected in the listbox
[ "Display", "the", "current", "sequences", "selected", "in", "the", "listbox" ]
[ "\"\"\"Display the current sequences selected in the listbox\"\"\"", "# Reset this if main window has been cleared while listbox open", "# Figure out the selected seq and display in textbox", "#tmp_sel=self.details.curselection()", "# set positions above main seq", "# Display multiple sequences at once by...
[ { "param": "self", "type": null }, { "param": "event", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "event", "type": null, "docstring": null, "docstring_tokens": ...
b8840143c56d36dc7944c001646d41a0066171e4
shambo001/peat
PEATDB/DNAtool/DNA_sequencing.py
[ "MIT" ]
Python
change_seq_direction
<not_specific>
def change_seq_direction(self,event=None): """Sets forward or reverse sense for entry based on single/double-click""" #pop up dialog box here first time this entry is selected #sel=self.details.curselection() items = map(int, self.details.curselection()) num=items[0] name...
Sets forward or reverse sense for entry based on single/double-click
Sets forward or reverse sense for entry based on single/double-click
[ "Sets", "forward", "or", "reverse", "sense", "for", "entry", "based", "on", "single", "/", "double", "-", "click" ]
def change_seq_direction(self,event=None): items = map(int, self.details.curselection()) num=items[0] name=self.seq_list[num] if self.seq_list_direction[name]=='f': self.details.itemconfig(num,fg='red') self.seq_list_direction[name]=='r' else: ...
[ "def", "change_seq_direction", "(", "self", ",", "event", "=", "None", ")", ":", "items", "=", "map", "(", "int", ",", "self", ".", "details", ".", "curselection", "(", ")", ")", "num", "=", "items", "[", "0", "]", "name", "=", "self", ".", "seq_li...
Sets forward or reverse sense for entry based on single/double-click
[ "Sets", "forward", "or", "reverse", "sense", "for", "entry", "based", "on", "single", "/", "double", "-", "click" ]
[ "\"\"\"Sets forward or reverse sense for entry based on single/double-click\"\"\"", "#pop up dialog box here first time this entry is selected", "#sel=self.details.curselection()" ]
[ { "param": "self", "type": null }, { "param": "event", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "event", "type": null, "docstring": null, "docstring_tokens": ...
b8840143c56d36dc7944c001646d41a0066171e4
shambo001/peat
PEATDB/DNAtool/DNA_sequencing.py
[ "MIT" ]
Python
load_Zip
<not_specific>
def load_Zip(self,event=None): """Loads sequences from a zip file and show items in the details widget""" zfilename = None zfilename = self.open_zipfile() if zfilename == None: return zfile = zipfile.ZipFile( zfilename, "r" ) zfile.printdir() self.seq...
Loads sequences from a zip file and show items in the details widget
Loads sequences from a zip file and show items in the details widget
[ "Loads", "sequences", "from", "a", "zip", "file", "and", "show", "items", "in", "the", "details", "widget" ]
def load_Zip(self,event=None): zfilename = None zfilename = self.open_zipfile() if zfilename == None: return zfile = zipfile.ZipFile( zfilename, "r" ) zfile.printdir() self.seq_list=[] for info in zfile.infolist(): fname = info.filename ...
[ "def", "load_Zip", "(", "self", ",", "event", "=", "None", ")", ":", "zfilename", "=", "None", "zfilename", "=", "self", ".", "open_zipfile", "(", ")", "if", "zfilename", "==", "None", ":", "return", "zfile", "=", "zipfile", ".", "ZipFile", "(", "zfile...
Loads sequences from a zip file and show items in the details widget
[ "Loads", "sequences", "from", "a", "zip", "file", "and", "show", "items", "in", "the", "details", "widget" ]
[ "\"\"\"Loads sequences from a zip file and show items in the details widget\"\"\"", "# decompress each file's data", "#data = zfile.read(fname)", "#print data" ]
[ { "param": "self", "type": null }, { "param": "event", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "event", "type": null, "docstring": null, "docstring_tokens": ...
70c95c080e7643064aab176f3d6c440bd1816f44
shambo001/peat
pKa/get_muts.py
[ "MIT" ]
Python
main
<not_specific>
def main(options,args): """Extract mutations from a multiple sequence alignment""" import PEATDB.sequence_alignment as SA if not options.fasta: alignment=SA.read_clustal_aln_file(args[0]) else: alignment=SA.read_fasta_aln_file(args[0]) print sorted(alignment.keys()) HEWL_seq=ali...
Extract mutations from a multiple sequence alignment
Extract mutations from a multiple sequence alignment
[ "Extract", "mutations", "from", "a", "multiple", "sequence", "alignment" ]
def main(options,args): import PEATDB.sequence_alignment as SA if not options.fasta: alignment=SA.read_clustal_aln_file(args[0]) else: alignment=SA.read_fasta_aln_file(args[0]) print sorted(alignment.keys()) HEWL_seq=alignment[options.wt] fd=open('mutations.txt','w') fd2=open...
[ "def", "main", "(", "options", ",", "args", ")", ":", "import", "PEATDB", ".", "sequence_alignment", "as", "SA", "if", "not", "options", ".", "fasta", ":", "alignment", "=", "SA", ".", "read_clustal_aln_file", "(", "args", "[", "0", "]", ")", "else", "...
Extract mutations from a multiple sequence alignment
[ "Extract", "mutations", "from", "a", "multiple", "sequence", "alignment" ]
[ "\"\"\"Extract mutations from a multiple sequence alignment\"\"\"", "#", "#", "#print 'Now looking at position',real_pos", "#", "# Calculate frequencies of observation", "#", "#print res_observed.keys()", "#", "# -----", "#", "#", "#", "# Within the PDB file?", "#", "#print muttext", ...
[ { "param": "options", "type": null }, { "param": "args", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "options", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "args", "type": null, "docstring": null, "docstring_tokens"...
b9d89dcef3eba497e0964f68844e35354311170d
shambo001/peat
PEATDB/zodbtest.py
[ "MIT" ]
Python
Timeit
<not_specific>
def Timeit(func,number=1,module="__main__"): """ A wrapper which can be used to time any function """ name = func.__name__ t = timeit.Timer("%s()"%name, "from %s import %s" % (module, name)) return "%.2f usec/pass" % (1000000*t.timeit(number=number)/number)
A wrapper which can be used to time any function
A wrapper which can be used to time any function
[ "A", "wrapper", "which", "can", "be", "used", "to", "time", "any", "function" ]
def Timeit(func,number=1,module="__main__"): name = func.__name__ t = timeit.Timer("%s()"%name, "from %s import %s" % (module, name)) return "%.2f usec/pass" % (1000000*t.timeit(number=number)/number)
[ "def", "Timeit", "(", "func", ",", "number", "=", "1", ",", "module", "=", "\"__main__\"", ")", ":", "name", "=", "func", ".", "__name__", "t", "=", "timeit", ".", "Timer", "(", "\"%s()\"", "%", "name", ",", "\"from %s import %s\"", "%", "(", "module",...
A wrapper which can be used to time any function
[ "A", "wrapper", "which", "can", "be", "used", "to", "time", "any", "function" ]
[ "\"\"\" A wrapper which can be used to time any function \"\"\"" ]
[ { "param": "func", "type": null }, { "param": "number", "type": null }, { "param": "module", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "func", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "number", "type": null, "docstring": null, "docstring_tokens":...
b9d89dcef3eba497e0964f68844e35354311170d
shambo001/peat
PEATDB/zodbtest.py
[ "MIT" ]
Python
createdb
<not_specific>
def createdb(local=None, server=None, project=None, username=None, norecs=1000): """Create and add some test data""" if local != None: if os.path.exists(local): for i in ['.lock','.index','']: try: os.remove(local+i) except: ...
Create and add some test data
Create and add some test data
[ "Create", "and", "add", "some", "test", "data" ]
def createdb(local=None, server=None, project=None, username=None, norecs=1000): if local != None: if os.path.exists(local): for i in ['.lock','.index','']: try: os.remove(local+i) except: pass DB = PDatabase(local=l...
[ "def", "createdb", "(", "local", "=", "None", ",", "server", "=", "None", ",", "project", "=", "None", ",", "username", "=", "None", ",", "norecs", "=", "1000", ")", ":", "if", "local", "!=", "None", ":", "if", "os", ".", "path", ".", "exists", "...
Create and add some test data
[ "Create", "and", "add", "some", "test", "data" ]
[ "\"\"\"Create and add some test data\"\"\"", "#DB.addField('ekin', 'General')", "#DB.data[c].ekin = E" ]
[ { "param": "local", "type": null }, { "param": "server", "type": null }, { "param": "project", "type": null }, { "param": "username", "type": null }, { "param": "norecs", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "local", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "server", "type": null, "docstring": null, "docstring_tokens"...
b9d89dcef3eba497e0964f68844e35354311170d
shambo001/peat
PEATDB/zodbtest.py
[ "MIT" ]
Python
checkdb
<not_specific>
def checkdb(server=None, project=None, local=None): """test basic ops for the db""" if server != None: DB = PDatabase(server=server, port=8080, username='farrell', password='123', project=project) else: DB = PDatabase(local=local) pr...
test basic ops for the db
test basic ops for the db
[ "test", "basic", "ops", "for", "the", "db" ]
def checkdb(server=None, project=None, local=None): if server != None: DB = PDatabase(server=server, port=8080, username='farrell', password='123', project=project) else: DB = PDatabase(local=local) print DB print DB['userfields'] ...
[ "def", "checkdb", "(", "server", "=", "None", ",", "project", "=", "None", ",", "local", "=", "None", ")", ":", "if", "server", "!=", "None", ":", "DB", "=", "PDatabase", "(", "server", "=", "server", ",", "port", "=", "8080", ",", "username", "=",...
test basic ops for the db
[ "test", "basic", "ops", "for", "the", "db" ]
[ "\"\"\"test basic ops for the db\"\"\"", "#DB.listRecs()", "'''first = DB.data.keys()[0]\n rec = DB.data[first] \n for k in rec.keys():\n print type(rec[k])'''" ]
[ { "param": "server", "type": null }, { "param": "project", "type": null }, { "param": "local", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "server", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "project", "type": null, "docstring": null, "docstring_token...
b9d89dcef3eba497e0964f68844e35354311170d
shambo001/peat
PEATDB/zodbtest.py
[ "MIT" ]
Python
testBlob
<not_specific>
def testBlob(): """write a file as binary data to blob and read back""" from ZODB.PersistentMapping import PersistentMapping import mimetypes from PILView import PILViewer DB = PDatabase(server='localhost',port=8090, username='farrell', password='123') def addfile(...
write a file as binary data to blob and read back
write a file as binary data to blob and read back
[ "write", "a", "file", "as", "binary", "data", "to", "blob", "and", "read", "back" ]
def testBlob(): from ZODB.PersistentMapping import PersistentMapping import mimetypes from PILView import PILViewer DB = PDatabase(server='localhost',port=8090, username='farrell', password='123') def addfile(fname): myblob = Blob() b=myblob.open('w') ...
[ "def", "testBlob", "(", ")", ":", "from", "ZODB", ".", "PersistentMapping", "import", "PersistentMapping", "import", "mimetypes", "from", "PILView", "import", "PILViewer", "DB", "=", "PDatabase", "(", "server", "=", "'localhost'", ",", "port", "=", "8090", ","...
write a file as binary data to blob and read back
[ "write", "a", "file", "as", "binary", "data", "to", "blob", "and", "read", "back" ]
[ "\"\"\"write a file as binary data to blob and read back\"\"\"", "#app = PILViewer(imgfile=f.name)", "#app.mainloop()" ]
[]
{ "returns": [], "raises": [], "params": [], "outlier_params": [], "others": [] }
b9d89dcef3eba497e0964f68844e35354311170d
shambo001/peat
PEATDB/zodbtest.py
[ "MIT" ]
Python
testLoading
<not_specific>
def testLoading(): """Test loading times for large DB""" from PEATDB.PEATTables import PEATTableModel t1 = time() DB = PDatabase(local='large.fs') #DB = PDatabase(server='localhost', port=8080, username='farrell', # password='123', project='large') t2=time() pr...
Test loading times for large DB
Test loading times for large DB
[ "Test", "loading", "times", "for", "large", "DB" ]
def testLoading(): from PEATDB.PEATTables import PEATTableModel t1 = time() DB = PDatabase(local='large.fs') t2=time() print round(t2 - t1,2) print DB.getRecs() t3=time() print round(t3 - t2,2) print DB.meta t4=time() print t4 - t3 M = PEATTableModel(DB) print M t...
[ "def", "testLoading", "(", ")", ":", "from", "PEATDB", ".", "PEATTables", "import", "PEATTableModel", "t1", "=", "time", "(", ")", "DB", "=", "PDatabase", "(", "local", "=", "'large.fs'", ")", "t2", "=", "time", "(", ")", "print", "round", "(", "t2", ...
Test loading times for large DB
[ "Test", "loading", "times", "for", "large", "DB" ]
[ "\"\"\"Test loading times for large DB\"\"\"", "#DB = PDatabase(server='localhost', port=8080, username='farrell',", "# password='123', project='large') " ]
[]
{ "returns": [], "raises": [], "params": [], "outlier_params": [], "others": [] }
b9d89dcef3eba497e0964f68844e35354311170d
shambo001/peat
PEATDB/zodbtest.py
[ "MIT" ]
Python
testMemory
<not_specific>
def testMemory(): """test memory behaviour of DB, how can cache be managed""" DB = PDatabase(server='localhost', username='farrell', password='123', project='novo') #DB = PDatabase(local='large.fs') print DB db = DB.db print db.cacheSize() for k in DB.getRecs()[:50]...
test memory behaviour of DB, how can cache be managed
test memory behaviour of DB, how can cache be managed
[ "test", "memory", "behaviour", "of", "DB", "how", "can", "cache", "be", "managed" ]
def testMemory(): DB = PDatabase(server='localhost', username='farrell', password='123', project='novo') print DB db = DB.db print db.cacheSize() for k in DB.getRecs()[:50]: r=DB[k] r.name if db.cacheSize()>500: db.cacheMinimize() prin...
[ "def", "testMemory", "(", ")", ":", "DB", "=", "PDatabase", "(", "server", "=", "'localhost'", ",", "username", "=", "'farrell'", ",", "password", "=", "'123'", ",", "project", "=", "'novo'", ")", "print", "DB", "db", "=", "DB", ".", "db", "print", "...
test memory behaviour of DB, how can cache be managed
[ "test", "memory", "behaviour", "of", "DB", "how", "can", "cache", "be", "managed" ]
[ "\"\"\"test memory behaviour of DB, how can cache be managed\"\"\"", "#DB = PDatabase(local='large.fs')", "#print k" ]
[]
{ "returns": [], "raises": [], "params": [], "outlier_params": [], "others": [] }
b9d89dcef3eba497e0964f68844e35354311170d
shambo001/peat
PEATDB/zodbtest.py
[ "MIT" ]
Python
convertClass
<not_specific>
def convertClass(): """Convert records to proper module name""" project='test' DB=PDatabase(server='localhost',port=8080, username='farrell',password='123', project=project) for k in DB.getRecs(): r=PEATRecord(k) rec = DB.data[k] print rec.__cl...
Convert records to proper module name
Convert records to proper module name
[ "Convert", "records", "to", "proper", "module", "name" ]
def convertClass(): project='test' DB=PDatabase(server='localhost',port=8080, username='farrell',password='123', project=project) for k in DB.getRecs(): r=PEATRecord(k) rec = DB.data[k] print rec.__class__ for f in rec.getFields(): ...
[ "def", "convertClass", "(", ")", ":", "project", "=", "'test'", "DB", "=", "PDatabase", "(", "server", "=", "'localhost'", ",", "port", "=", "8080", ",", "username", "=", "'farrell'", ",", "password", "=", "'123'", ",", "project", "=", "project", ")", ...
Convert records to proper module name
[ "Convert", "records", "to", "proper", "module", "name" ]
[ "\"\"\"Convert records to proper module name\"\"\"" ]
[]
{ "returns": [], "raises": [], "params": [], "outlier_params": [], "others": [] }
b9d89dcef3eba497e0964f68844e35354311170d
shambo001/peat
PEATDB/zodbtest.py
[ "MIT" ]
Python
convertEkinprjs
<not_specific>
def convertEkinprjs(local=None, server=None, project=None, username=None): """convert old ekin prjs in a db to new""" if local != None: DB = PDatabase(local=local) elif server != None: DB = PDatabase(server=server, username='farrell', port=8080, ...
convert old ekin prjs in a db to new
convert old ekin prjs in a db to new
[ "convert", "old", "ekin", "prjs", "in", "a", "db", "to", "new" ]
def convertEkinprjs(local=None, server=None, project=None, username=None): if local != None: DB = PDatabase(local=local) elif server != None: DB = PDatabase(server=server, username='farrell', port=8080, password='123', project=project) for f in D...
[ "def", "convertEkinprjs", "(", "local", "=", "None", ",", "server", "=", "None", ",", "project", "=", "None", ",", "username", "=", "None", ")", ":", "if", "local", "!=", "None", ":", "DB", "=", "PDatabase", "(", "local", "=", "local", ")", "elif", ...
convert old ekin prjs in a db to new
[ "convert", "old", "ekin", "prjs", "in", "a", "db", "to", "new" ]
[ "\"\"\"convert old ekin prjs in a db to new\"\"\"", "#ek.prettyPrint() " ]
[ { "param": "local", "type": null }, { "param": "server", "type": null }, { "param": "project", "type": null }, { "param": "username", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "local", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "server", "type": null, "docstring": null, "docstring_tokens"...
a3c82e3761662550d6551c78f3a376c94689caec
shambo001/peat
pKa/Design_pKa.py
[ "MIT" ]
Python
calculate_pKa_change
<not_specific>
def calculate_pKa_change(self,mutations): """ Calculate the dpKa value(s) for the residue(s) in self.desired_pKa_changes and calculate the score for this set of mutations""" # # Which method are we going to use? # dpKas=None if not self.params['tabulated']: ...
Calculate the dpKa value(s) for the residue(s) in self.desired_pKa_changes and calculate the score for this set of mutations
Calculate the dpKa value(s) for the residue(s) in self.desired_pKa_changes and calculate the score for this set of mutations
[ "Calculate", "the", "dpKa", "value", "(", "s", ")", "for", "the", "residue", "(", "s", ")", "in", "self", ".", "desired_pKa_changes", "and", "calculate", "the", "score", "for", "this", "set", "of", "mutations" ]
def calculate_pKa_change(self,mutations): Which method are we going to use? dpKas=None if not self.params['tabulated']: Explicit (each combination of mutations is evaluated separately) dpKas=self.calculate_dpKas_explicit(mutations,return_protstates=self.params['stabilit...
[ "def", "calculate_pKa_change", "(", "self", ",", "mutations", ")", ":", "dpKas", "=", "None", "if", "not", "self", ".", "params", "[", "'tabulated'", "]", ":", "dpKas", "=", "self", ".", "calculate_dpKas_explicit", "(", "mutations", ",", "return_protstates", ...
Calculate the dpKa value(s) for the residue(s) in self.desired_pKa_changes and calculate the score for this set of mutations
[ "Calculate", "the", "dpKa", "value", "(", "s", ")", "for", "the", "residue", "(", "s", ")", "in", "self", ".", "desired_pKa_changes", "and", "calculate", "the", "score", "for", "this", "set", "of", "mutations" ]
[ "\"\"\" Calculate the dpKa value(s) for the residue(s) in self.desired_pKa_changes\n and calculate the score for this set of mutations\"\"\"", "#", "# Which method are we going to use?", "#", "#", "# Explicit (each combination of mutations is evaluated separately)", "#", "#", "# Tabulated...
[ { "param": "self", "type": null }, { "param": "mutations", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "mutations", "type": null, "docstring": null, "docstring_token...
a3c82e3761662550d6551c78f3a376c94689caec
shambo001/peat
pKa/Design_pKa.py
[ "MIT" ]
Python
find_reporter_groups
<not_specific>
def find_reporter_groups(self,mutations,check_groups=False): """Find all the reporter groups that are valid with this set of mutations If check_groups is True then check that the pKa values of the groups are inside pH_start and pH_stop """ if not check_groups: repor...
Find all the reporter groups that are valid with this set of mutations If check_groups is True then check that the pKa values of the groups are inside pH_start and pH_stop
Find all the reporter groups that are valid with this set of mutations If check_groups is True then check that the pKa values of the groups are inside pH_start and pH_stop
[ "Find", "all", "the", "reporter", "groups", "that", "are", "valid", "with", "this", "set", "of", "mutations", "If", "check_groups", "is", "True", "then", "check", "that", "the", "pKa", "values", "of", "the", "groups", "are", "inside", "pH_start", "and", "p...
def find_reporter_groups(self,mutations,check_groups=False): if not check_groups: reporter_groups=self.desired_pKa_changes.keys() else: If so requested get dpKa values for all wild type residues reporter_groups=[] groups=self.wt_pKas.keys() gr...
[ "def", "find_reporter_groups", "(", "self", ",", "mutations", ",", "check_groups", "=", "False", ")", ":", "if", "not", "check_groups", ":", "reporter_groups", "=", "self", ".", "desired_pKa_changes", ".", "keys", "(", ")", "else", ":", "reporter_groups", "=",...
Find all the reporter groups that are valid with this set of mutations If check_groups is True then check that the pKa values of the groups are inside pH_start and pH_stop
[ "Find", "all", "the", "reporter", "groups", "that", "are", "valid", "with", "this", "set", "of", "mutations", "If", "check_groups", "is", "True", "then", "check", "that", "the", "pKa", "values", "of", "the", "groups", "are", "inside", "pH_start", "and", "p...
[ "\"\"\"Find all the reporter groups that are valid with this set of mutations\n\n If check_groups is True then check that the pKa values of the groups are\n inside pH_start and pH_stop\n\n \"\"\"", "#", "# If so requested get dpKa values for all wild type residues", "#", "#", "# Make ...
[ { "param": "self", "type": null }, { "param": "mutations", "type": null }, { "param": "check_groups", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "mutations", "type": null, "docstring": null, "docstring_token...
a3c82e3761662550d6551c78f3a376c94689caec
shambo001/peat
pKa/Design_pKa.py
[ "MIT" ]
Python
dpKa_philn10
<not_specific>
def dpKa_philn10(self,mutation,target_residue,verbose=None): """ # For a given mutation, calculate the change in the pKa value if the target using phi/ln(10) """ # If we have no mutation, then we have no change # if not mutation: return 0.0 # #...
# For a given mutation, calculate the change in the pKa value if the target using phi/ln(10)
For a given mutation, calculate the change in the pKa value if the target using phi/ln(10)
[ "For", "a", "given", "mutation", "calculate", "the", "change", "in", "the", "pKa", "value", "if", "the", "target", "using", "phi", "/", "ln", "(", "10", ")" ]
def dpKa_philn10(self,mutation,target_residue,verbose=None): if not mutation: return 0.0 Check that target_residue and mutation is not the same residue import pKD_tools if pKD_tools.get_resnum_from_mut(mutation)==pKD_tools.get_resnum_from_res(target_residue): ret...
[ "def", "dpKa_philn10", "(", "self", ",", "mutation", ",", "target_residue", ",", "verbose", "=", "None", ")", ":", "if", "not", "mutation", ":", "return", "0.0", "import", "pKD_tools", "if", "pKD_tools", ".", "get_resnum_from_mut", "(", "mutation", ")", "=="...
For a given mutation, calculate the change in the pKa value if the target using phi/ln(10)
[ "For", "a", "given", "mutation", "calculate", "the", "change", "in", "the", "pKa", "value", "if", "the", "target", "using", "phi", "/", "ln", "(", "10", ")" ]
[ "\"\"\"\n # For a given mutation, calculate the change in the pKa value if the target using phi/ln(10)\n \"\"\"", "# If we have no mutation, then we have no change", "#", "#", "# Check that target_residue and mutation is not the same residue", "#", "#", "# Get the interaction energy ", ...
[ { "param": "self", "type": null }, { "param": "mutation", "type": null }, { "param": "target_residue", "type": null }, { "param": "verbose", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "mutation", "type": null, "docstring": null, "docstring_tokens...
a3c82e3761662550d6551c78f3a376c94689caec
shambo001/peat
pKa/Design_pKa.py
[ "MIT" ]
Python
calc_dpKa
<not_specific>
def calc_dpKa(self): """ # Calculate the dpKa for a particular set of mutations """ # Initialise # self.initialise('calcdpka') # # Calculate starting state (wt pKa vals) # none_muts=[None] # # Set the mutations # ...
# Calculate the dpKa for a particular set of mutations
Calculate the dpKa for a particular set of mutations
[ "Calculate", "the", "dpKa", "for", "a", "particular", "set", "of", "mutations" ]
def calc_dpKa(self): self.initialise('calcdpka') Calculate starting state (wt pKa vals) none_muts=[None] Set the mutations mutations=self.params['mutations'] if not mutations: self.O._print('You have to specify mutations with the -mutations flag when calcula...
[ "def", "calc_dpKa", "(", "self", ")", ":", "self", ".", "initialise", "(", "'calcdpka'", ")", "none_muts", "=", "[", "None", "]", "mutations", "=", "self", ".", "params", "[", "'mutations'", "]", "if", "not", "mutations", ":", "self", ".", "O", ".", ...
Calculate the dpKa for a particular set of mutations
[ "Calculate", "the", "dpKa", "for", "a", "particular", "set", "of", "mutations" ]
[ "\"\"\"\n # Calculate the dpKa for a particular set of mutations\n \"\"\"", "# Initialise", "#", "#", "# Calculate starting state (wt pKa vals)", "#", "#", "# Set the mutations", "#", "#", "# Do we have multiple sets of multiple mutations?", "#", "#", "# Multiple sets of muta...
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
a3c82e3761662550d6551c78f3a376c94689caec
shambo001/peat
pKa/Design_pKa.py
[ "MIT" ]
Python
close_stdout
<not_specific>
def close_stdout(self): """Closes std out and dumps output to file""" import tempfile, sys self.newstdout=tempfile.TemporaryFile() self.old_stdout=sys.stdout sys.stdout=self.newstdout return
Closes std out and dumps output to file
Closes std out and dumps output to file
[ "Closes", "std", "out", "and", "dumps", "output", "to", "file" ]
def close_stdout(self): import tempfile, sys self.newstdout=tempfile.TemporaryFile() self.old_stdout=sys.stdout sys.stdout=self.newstdout return
[ "def", "close_stdout", "(", "self", ")", ":", "import", "tempfile", ",", "sys", "self", ".", "newstdout", "=", "tempfile", ".", "TemporaryFile", "(", ")", "self", ".", "old_stdout", "=", "sys", ".", "stdout", "sys", ".", "stdout", "=", "self", ".", "ne...
Closes std out and dumps output to file
[ "Closes", "std", "out", "and", "dumps", "output", "to", "file" ]
[ "\"\"\"Closes std out and dumps output to file\"\"\"" ]
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }
a3c82e3761662550d6551c78f3a376c94689caec
shambo001/peat
pKa/Design_pKa.py
[ "MIT" ]
Python
run_opt
<not_specific>
def run_opt(defaults,new_instance=None,mutant_PDB_files={}): """ Do post-processing of defaults and branch into correct routine """ # # Did we get a new design instance? # global G_Design_instance if new_instance: G_Design_instance=None # # Reformat parameters first thoug...
Do post-processing of defaults and branch into correct routine
Do post-processing of defaults and branch into correct routine
[ "Do", "post", "-", "processing", "of", "defaults", "and", "branch", "into", "correct", "routine" ]
def run_opt(defaults,new_instance=None,mutant_PDB_files={}): Did we get a new design instance? global G_Design_instance if new_instance: G_Design_instance=None Reformat parameters first though... params={} for key in defaults.keys(): params[key]=defaults[key][0] Print setu...
[ "def", "run_opt", "(", "defaults", ",", "new_instance", "=", "None", ",", "mutant_PDB_files", "=", "{", "}", ")", ":", "global", "G_Design_instance", "if", "new_instance", ":", "G_Design_instance", "=", "None", "params", "=", "{", "}", "for", "key", "in", ...
Do post-processing of defaults and branch into correct routine
[ "Do", "post", "-", "processing", "of", "defaults", "and", "branch", "into", "correct", "routine" ]
[ "\"\"\"\n Do post-processing of defaults and branch into correct routine\n \"\"\"", "#", "# Did we get a new design instance?", "#", "#", "# Reformat parameters first though...", "#", "#", "# Print setup, and ask if ok", "#", "#", "# Start the design process", "#", "# If we have an i...
[ { "param": "defaults", "type": null }, { "param": "new_instance", "type": null }, { "param": "mutant_PDB_files", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "defaults", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null }, { "identifier": "new_instance", "type": null, "docstring": null, "docstrin...
71f14c6afddd3e5ecb26462c06a6011f9100d114
shambo001/peat
DNATool2/Base.py
[ "MIT" ]
Python
savePrefs
<not_specific>
def savePrefs(self): """Save prefs to a preferences instance""" self.preferences = Preferences('DNATool2',{}) for key in self.defaultprefs: self.preferences.set(key, self.__dict__[key]) return
Save prefs to a preferences instance
Save prefs to a preferences instance
[ "Save", "prefs", "to", "a", "preferences", "instance" ]
def savePrefs(self): self.preferences = Preferences('DNATool2',{}) for key in self.defaultprefs: self.preferences.set(key, self.__dict__[key]) return
[ "def", "savePrefs", "(", "self", ")", ":", "self", ".", "preferences", "=", "Preferences", "(", "'DNATool2'", ",", "{", "}", ")", "for", "key", "in", "self", ".", "defaultprefs", ":", "self", ".", "preferences", ".", "set", "(", "key", ",", "self", "...
Save prefs to a preferences instance
[ "Save", "prefs", "to", "a", "preferences", "instance" ]
[ "\"\"\"Save prefs to a preferences instance\"\"\"" ]
[ { "param": "self", "type": null } ]
{ "returns": [], "raises": [], "params": [ { "identifier": "self", "type": null, "docstring": null, "docstring_tokens": [], "default": null, "is_optional": null } ], "outlier_params": [], "others": [] }