pKaTool/pKaTool_main.py
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[:]
        #
        # Then load the new stuff
        #
        new_calc=self.calc_select.get()
        self.X=self.calcs[new_calc]['instance']
        self.titration_curves=self.calcs[new_calc]['titcurv']
        self.pkavals=self.calcs[new_calc]['pkavals'].copy()
        if self.X:
            self.matrix=self.X.read_matrix()
        #
        self.groups=self.titration_curves.keys()
        self.groups.sort()
        self.current_selected_calc=new_calc
        #
        # Update the selection and all groups
        #
        self.update_all_groups()
        self.selected_groups=self.calcs[new_calc]['selected_groups']
        self.update_selected_groups()
        #
        # Set pdbfilename
        #
        self.pdbfilename=new_calc
        #
        # Read the PDB file
        #
        import Protool
        self.Protool_instance=Protool.structureIO()
        self.Protool_instance.parsepdb(lines=self.calcs[new_calc]['pdblines'])
        return
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()
        self.X=self.calcs[new_calc]['instance']
        self.titration_curves=self.calcs[new_calc]['titcurv']
        self.pkavals=self.calcs[new_calc]['pkavals'].copy()
        if self.X:
            self.matrix=self.X.read_matrix()
        self.groups=self.titration_curves.keys()
        self.groups.sort()
        self.current_selected_calc=new_calc
         Update the selection and all groups
        self.update_all_groups()
        self.selected_groups=self.calcs[new_calc]['selected_groups']
        self.update_selected_groups()
         Set pdbfilename
        self.pdbfilename=new_calc
         Read the PDB file
        import Protool
        self.Protool_instance=Protool.structureIO()
        self.Protool_instance.parsepdb(lines=self.calcs[new_calc]['pdblines'])
        return
def update_selected_calc ( self , event = None ) : if self . current_selected_calc : self . calcs [ self . current_selected_calc ] [ 'selected_groups' ] = self . selected_groups [ : ] new_calc = self . calc_select . get ( ) self . X = self . calcs [ new_calc ] [ 'instance' ] self . titration_curves = self . calcs [ new_calc ] [ 'titcurv' ] self . pkavals = self . calcs [ new_calc ] [ 'pkavals' ] . copy ( ) if self . X : self . matrix = self . X . read_matrix ( ) self . groups = self . titration_curves . keys ( ) self . groups . sort ( ) self . current_selected_calc = new_calc self . update_all_groups ( ) self . selected_groups = self . calcs [ new_calc ] [ 'selected_groups' ] self . update_selected_groups ( ) self . pdbfilename = new_calc import Protool self . Protool_instance = Protool . structureIO ( ) self . Protool_instance . parsepdb ( lines = self . calcs [ new_calc ] [ 'pdblines' ] ) return
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 #
self
event