[BioPython] disordered atoms in pdb

Peter biopython at maubp.freeserve.co.uk
Mon Nov 17 10:07:43 UTC 2008


Fabian Glaser wrote:
> Hi,
>
> I am quite new to biopython, so forgive me if I am asking trivial questions
> for a while...

Hi Fabian,

> I am successfully reading and updating pdb files with biopython, with only
> one exception: disordered atoms. I understand they are part of a different
> object than regular atoms, but when I am trying for example to change their
> temperature factor values with the following code:
>
>           if residue.is_disordered():                           for atom in
> residue:
>                   print residue, atom, atom.get_bfactor()
>                       atom.set_bfactor(0)
>                   print residue, atom, atom.get_bfactor()

Your indentation went funny in the email.  Could you repeat the
example, and add a little bit more code to load the PDB file and
select this residue?  (any PDB file with a disordered residue should
be fine).

> The code if there is more than one option, for example A and B, only the
> first one is updated:
>
> <Residue LYS het=  resseq=165 icode= > <Disordered Atom CB> 23.48
> <Residue LYS het=  resseq=165 icode= > <Disordered Atom CB> 0
> <Residue LYS het=  resseq=165 icode= > <Disordered Atom CG> 25.38
> <Residue LYS het=  resseq=165 icode= > <Disordered Atom CG> 0

In this example atoms CB and CG seem to have both had their bfactor
updated.  I don't understand what is wrong.

Peter



More information about the Biopython mailing list