mailMy XH bond distribution scripts, Re: NH bond vector orientation figure in pymol/molmol


Others Months | Index by Date | Thread Index
>>   [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Header


Content

Posted by Edward d'Auvergne on December 09, 2007 - 15:49:
Hi,

I didn't include the XH bond distribution scripts with relax.  There
were a couple of these to generate the figure.  These 2 file have been
attached to this message.  'dist.py' generates parts c and d whereas
'dist_core.py' generates parts a and b.  For those who are interested,
this figure is from my PhD thesis located at
http://eprints.infodiv.unimelb.edu.au/archive/00002799/.  Note that the
file 'core' referred to in 'dist_core.py' is just a text file with one
residue number per line.  Also, depending on how you look at these
scripts, be careful and maybe remove any line wrapping.  I hope you find
this useful.

Regards,

Edward



On Mon, 2007-12-03 at 12:26 -0500, Douglas Kojetin wrote:
Hi Edward,

Is a relax script available that creates a PyMOL (or MOLMOL)  
structure figure of the NH bond vector orientations, as shown in your  
dissertation (Figure 7.8; page 252)?

Thanks,
Doug
# Script for creating a PDB representation of the distribution of XH bond 
vectors.

# Create the run.
name = 'vectors'
run.create(name, 'mf')

# Load the PDB file.
structure.read_pdb(name, '../1F35_H.pdb')

# Select solely the XH vectors used in the analysis.
select.read(name, file='../rates.txt', change_all=1, column=1)

# Select solely the core residues which are already selected.
select.read(name, file='core', boolean='AND')

# Count the number of selected residues.
sel_count = 0
for i in xrange(len(self.relax.data.res[name])):
    sel_count = sel_count + self.relax.data.res[name][i].select
print "Number of residues selected: %d\n\n\n\n\n" % sel_count

# Set the XH vectors.
structure.vectors(name)

# Create the PDB file.
structure.create_vector_dist(name, force=1)

# PyMOL.
pymol.view(name)
pymol.cartoon(name)
pymol.vector_dist(name)
# Script for creating a PDB representation of the distribution of XH bond 
vectors.

# Create the run.
name = 'vectors'
run.create(name, 'mf')

# Load the PDB file.
structure.read_pdb(name, '../1F35_H.pdb')

# Select solely the XH vectors used in the analysis.
select.read(name, file='../rates.txt', change_all=1, column=1)

# Set the XH vectors.
structure.vectors(name)

# Create the PDB file.
structure.create_vector_dist(name, force=1)

# PyMOL.
pymol.view(name)
pymol.cartoon(name)
pymol.vector_dist(name)

Related Messages


Powered by MHonArc, Updated Sun Dec 09 17:21:08 2007