mailr4563 - /branches/N_state_model/prompt/n_state_model.py


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

Header


Content

Posted by edward on January 09, 2008 - 17:30:
Author: bugman
Date: Wed Jan  9 17:30:22 2008
New Revision: 4563

URL: http://svn.gna.org/viewcvs/relax?rev=4563&view=rev
Log:
Wrote the interface of the n_state_model.set_domain() user function.


Modified:
    branches/N_state_model/prompt/n_state_model.py

Modified: branches/N_state_model/prompt/n_state_model.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/N_state_model/prompt/n_state_model.py?rev=4563&r1=4562&r2=4563&view=diff
==============================================================================
--- branches/N_state_model/prompt/n_state_model.py (original)
+++ branches/N_state_model/prompt/n_state_model.py Wed Jan  9 17:30:22 2008
@@ -42,4 +42,49 @@
         self.__relax__ = relax
 
 
+    def set_domain(self, tensor=None, domain=None):
+        """Set the domain label for the alignment tensor.
 
+        Keyword Arguments
+        ~~~~~~~~~~~~~~~~~
+
+        tensor:  The alignment tensor to assign the domain label to.
+
+        domain:  The domain label.
+
+
+        Description
+        ~~~~~~~~~~~
+
+        Prior to optimisation of the N-state model, the domain to which each 
alignment tensor
+        belongs must be specified.
+
+
+        Examples
+        ~~~~~~~~
+
+        To link the alignment tensor loaded as 'chi3 C-dom' to the 
C-terminal domain 'C', type:
+
+        relax> n_state_model.set_domain(tensor='chi3 C-dom', domain='C')
+        """
+
+        # Function intro text.
+        if self.__relax__.interpreter.intro:
+            text = sys.ps3 + "n_state_model.set_domain("
+            text = text + "tensor=" + `tensor`
+            text = text + ", domain=" + `domain` + ")"
+            print text
+
+        # Tensor argument.
+        if type(tensor) != str:
+            raise RelaxStrError, ('tensor', tensor)
+
+        # Domain argument.
+        if type(domain) != str:
+            raise RelaxStrError, ('domain', domain)
+
+        # Execute the functional code.
+        n_state_model.set_domain(tensor=tensor, domain=domain)
+
+
+




Related Messages


Powered by MHonArc, Updated Wed Jan 09 17:40:11 2008