mailr6714 - /branches/rdc_analysis/generic_fns/structure/internal.py


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

Header


Content

Posted by edward on July 05, 2008 - 01:21:
Author: bugman
Date: Sat Jul  5 01:21:12 2008
New Revision: 6714

URL: http://svn.gna.org/viewcvs/relax?rev=6714&view=rev
Log:
Fixed the creation of the ATOM, HETATM, and TER records.


Modified:
    branches/rdc_analysis/generic_fns/structure/internal.py

Modified: branches/rdc_analysis/generic_fns/structure/internal.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/rdc_analysis/generic_fns/structure/internal.py?rev=6714&r1=6713&r2=6714&view=diff
==============================================================================
--- branches/rdc_analysis/generic_fns/structure/internal.py (original)
+++ branches/rdc_analysis/generic_fns/structure/internal.py Sat Jul  5 
01:21:12 2008
@@ -812,7 +812,7 @@
             print "Creating the atomic coordinate records (ATOM, HETATM, and 
TER)."
 
             # Loop over the atomic data.
-            for i in xrange(len(struct.atom_names)):
+            for i in xrange(len(struct.atom_name)):
                 # Aliases.
                 atom_num = struct.atom_num[i]
                 atom_name = struct.atom_name[i]
@@ -846,15 +846,15 @@
                     element = ''
 
                 # Write the ATOM record.
-                if array[1] == 'ATOM':
+                if struct.pdb_record[i] == 'ATOM':
                     file.write("%-6s%5s %4s%1s%3s %1s%4s%1s   
%8.3f%8.3f%8.3f%6.2f%6.2f      %4s%2s%2s\n" % ('ATOM', atom_num, atom_name, 
'', res_name, chain_id, res_num, '', x, y, z, 1.0, 0, seg_id, element, ''))
 
                 # Write the HETATM record.
-                if array[1] == 'HETATM':
+                if struct.pdb_record[i] == 'HETATM':
                     file.write("%-6s%5s %4s%1s%3s %1s%4s%1s   
%8.3f%8.3f%8.3f%6.2f%6.2f      %4s%2s%2s\n" % ('HETATM', atom_num, atom_name, 
'', res_name, chain_id, res_num, '', x, y, z, 1.0, 0, seg_id, element, ''))
 
                 # Write the TER record.
-                if array[1] == 'TER':
+                if struct.pdb_record[i] == 'TER':
                     file.write("%-6s%5s      %3s %1s%4s%1s\n" % ('TER', 
atom_num, res_name, chain_id, res_num, ''))
 
 




Related Messages


Powered by MHonArc, Updated Sat Jul 05 01:40:17 2008