mailr12537 - in /branches/bruker_import/generic_fns: __init__.py pdc.py


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

Header


Content

Posted by edward on February 17, 2011 - 16:25:
Author: bugman
Date: Thu Feb 17 16:25:56 2011
New Revision: 12537

URL: http://svn.gna.org/viewcvs/relax?rev=12537&view=rev
Log:
Create a stub of a back-end for the pdc.read() user function.


Added:
    branches/bruker_import/generic_fns/pdc.py
Modified:
    branches/bruker_import/generic_fns/__init__.py

Modified: branches/bruker_import/generic_fns/__init__.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/bruker_import/generic_fns/__init__.py?rev=12537&r1=12536&r2=12537&view=diff
==============================================================================
--- branches/bruker_import/generic_fns/__init__.py (original)
+++ branches/bruker_import/generic_fns/__init__.py Thu Feb 17 16:25:56 2011
@@ -1,6 +1,6 @@
 
###############################################################################
 #                                                                            
 #
-# Copyright (C) 2004-2010 Edward d'Auvergne                                  
 #
+# Copyright (C) 2004-2011 Edward d'Auvergne                                  
 #
 #                                                                            
 #
 # This file is part of the program relax.                                    
 #
 #                                                                            
 #
@@ -39,6 +39,7 @@
             'palmer',
             'paramag',
             'pcs',
+            'pdc',
             'pipes',
             'pymol_control',
             'rdc',

Added: branches/bruker_import/generic_fns/pdc.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/bruker_import/generic_fns/pdc.py?rev=12537&view=auto
==============================================================================
--- branches/bruker_import/generic_fns/pdc.py (added)
+++ branches/bruker_import/generic_fns/pdc.py Thu Feb 17 16:25:56 2011
@@ -1,0 +1,45 @@
+###############################################################################
+#                                                                            
 #
+# Copyright (C) 2011 Edward d'Auvergne                                       
 #
+#                                                                            
 #
+# This file is part of the program relax.                                    
 #
+#                                                                            
 #
+# relax is free software; you can redistribute it and/or modify              
 #
+# it under the terms of the GNU General Public License as published by       
 #
+# the Free Software Foundation; either version 2 of the License, or          
 #
+# (at your option) any later version.                                        
 #
+#                                                                            
 #
+# relax is distributed in the hope that it will be useful,                   
 #
+# but WITHOUT ANY WARRANTY; without even the implied warranty of             
 #
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the              
 #
+# GNU General Public License for more details.                               
 #
+#                                                                            
 #
+# You should have received a copy of the GNU General Public License          
 #
+# along with relax; if not, write to the Free Software                       
 #
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA  
 #
+#                                                                            
 #
+###############################################################################
+
+# Module docstring.
+"""Module for the reading of Bruker Protein Dynamics Centre (PDC) files."""
+
+# relax module imports.
+from generic_fns.mol_res_spin import spin_loop
+from relax_errors import RelaxError
+
+
+def read(file=None, dir=None):
+    """Read the PDC data file and place all the data into the relax data 
store.
+
+    @keyword file:          The name of the file to open.
+    @type file:             str
+    @keyword dir:           The directory containing the file (defaults to 
the current directory if None).
+    @type dir:              str or None
+    """
+
+    # Test if the current pipe exists.
+    pipes.test()
+
+    # Test if sequence data is loaded.
+    if not exists_mol_res_spin_data():
+        raise RelaxNoSequenceError




Related Messages


Powered by MHonArc, Updated Thu Feb 17 17:00:02 2011