RdcPanda
Class Dipolar

java.lang.Object
  extended by RdcPanda.Dipolar
All Implemented Interfaces:
java.lang.Cloneable

public class Dipolar
extends java.lang.Object
implements java.lang.Cloneable

This class provides data structures processing experimental RDC data. Written by Lincong Wang (2001-2005) and Jianyang (Michael) Zeng (2005-2009).


Nested Class Summary
static class Dipolar.rdcComparator
          The Class rdcComparator.
 
Constructor Summary
Dipolar()
          Instantiates a new dipolar.
Dipolar(int no)
          Instantiates a new dipolar.
Dipolar(int no, java.lang.String resid, double rdc, double err)
          Instantiates a new dipolar.
 
Method Summary
 double getErr()
          Gets the err.
 double getRdc()
          Gets the rdc.
 java.lang.String getResidue()
          Gets the residue.
 int getResidueNo()
          Gets the residue no.
static void main(java.lang.String[] argv)
          The main method for testing.
 void outPutRDCXplorFormat(java.util.Vector vecRDCs, java.lang.String atom1, java.lang.String atom2)
          output the RDCs in the xplor format.
 java.util.Vector rdcRead(java.lang.String filename)
          A method for reading files with RDC restraints.
 java.util.Vector rdcRead(java.lang.String filename, double dbScale)
          A method for reading files with RDC restraints.
 java.util.Vector rdcReader_old(java.lang.String filename, java.util.Vector idVec, java.lang.String idType)
          This is an old function.
 java.util.Vector<java.util.Vector<Dipolar>> rdcReader(java.lang.String filename, java.util.Vector<IDof2aryStructure> idVec, java.lang.String idType)
          read RDC data file for a fragment as defined by secondary structure identification.
 java.util.Vector<java.util.Vector<Dipolar>> rdcReader(java.lang.String filename, java.util.Vector<IDof2aryStructure> idVec, java.lang.String idType, double dbSc)
          read RDC data file for a fragment as defined by secondary structure identification.
 java.util.Vector rdcReader4CNS(java.lang.String fileName, java.lang.String id, double ratio)
          A method for extracting RDC restraints from CNS format The required file format is: residue No.
 void setErr(double err)
          Sets the err.
 void setRdc(double rdc)
          Sets the rdc.
 void setResidueNo(int R)
          Sets the residue no.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Dipolar

public Dipolar()
Instantiates a new dipolar.


Dipolar

public Dipolar(int no)
Instantiates a new dipolar.

Parameters:
no - the no

Dipolar

public Dipolar(int no,
               java.lang.String resid,
               double rdc,
               double err)
Instantiates a new dipolar.

Parameters:
no - the no
resid - the resid
rdc - the rdc
err - the err
Method Detail

getResidueNo

public int getResidueNo()
Gets the residue no.

Returns:
the residue no

getResidue

public java.lang.String getResidue()
Gets the residue.

Returns:
the residue

getErr

public double getErr()
Gets the err.

Returns:
the err

getRdc

public double getRdc()
Gets the rdc.

Returns:
the rdc

setResidueNo

public void setResidueNo(int R)
Sets the residue no.

Parameters:
R - the new residue no

setErr

public void setErr(double err)
Sets the err.

Parameters:
err - the new err

setRdc

public void setRdc(double rdc)
Sets the rdc.

Parameters:
rdc - the new rdc

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

outPutRDCXplorFormat

public void outPutRDCXplorFormat(java.util.Vector vecRDCs,
                                 java.lang.String atom1,
                                 java.lang.String atom2)
output the RDCs in the xplor format.

Parameters:
vecRDCs - RDCs
atom1 - first atom name of the bond vector
atom2 - second atom name of the bond vector

rdcReader

public java.util.Vector<java.util.Vector<Dipolar>> rdcReader(java.lang.String filename,
                                                             java.util.Vector<IDof2aryStructure> idVec,
                                                             java.lang.String idType)
read RDC data file for a fragment as defined by secondary structure identification. file format is: residue No., RDC value, experimental error. Must have only three items per line. Otherwise, errors.

Parameters:
filename - the name of the file
idVec - the 2ary structure identification for the protein
idType - the 2ary type of the fragment
Returns:
a vector of RDC objects associated with the fragment.

rdcReader

public java.util.Vector<java.util.Vector<Dipolar>> rdcReader(java.lang.String filename,
                                                             java.util.Vector<IDof2aryStructure> idVec,
                                                             java.lang.String idType,
                                                             double dbSc)
read RDC data file for a fragment as defined by secondary structure identification. file format is: residue No., RDC value, experimental error. Must have only three items per line. Otherwise, errors.

Parameters:
filename - the name of the file
idVec - the 2ary structure identification for the protein
idType - the 2ary type of the fragment
dbSc - the db sc
Returns:
a vector of RDC objects associated with the fragment.

rdcReader_old

public java.util.Vector rdcReader_old(java.lang.String filename,
                                      java.util.Vector idVec,
                                      java.lang.String idType)
This is an old function. A method for reading files with RDC data for a fragment as defined by secondary structure identification. file format is: residue No. RDC value, experimental error. Must have only three items per line. Otherwise, errors.

Parameters:
filename - the name of the file
idVec - the secondary identification for the protein
idType - the 2ary type of the fragment
Returns:
a vector of RDC object associated with the fragment.

rdcReader4CNS

public java.util.Vector rdcReader4CNS(java.lang.String fileName,
                                      java.lang.String id,
                                      double ratio)
A method for extracting RDC restraints from CNS format The required file format is: residue No. RDC value, experimental error. Must have only three items per line. Otherwise, errors.

Parameters:
id - the identification of RDC such as NH or CH RDCs
fileName - the file name
ratio - the ratio
Returns:
a vector of RDC object

rdcRead

public java.util.Vector rdcRead(java.lang.String filename)
A method for reading files with RDC restraints. The required file format is: residue No. RDC value, experimental error. Must have only three items per line. Otherwise, errors.

Parameters:
filename - the name of the file
Returns:
a vector of RDC object

rdcRead

public java.util.Vector rdcRead(java.lang.String filename,
                                double dbScale)
A method for reading files with RDC restraints. The required file format is: residue No. RDC value, experimental error. Must have only three items per line. Otherwise, errors.

Parameters:
filename - the name of the file
dbScale - the db scale
Returns:
a vector of RDC object

main

public static void main(java.lang.String[] argv)
                 throws JampackException
The main method for testing.

Parameters:
argv - the arguments
Throws:
JampackException - the jampack exception