Main Page

From PyMOLWiki
Revision as of 12:51, 28 February 2005 by Tree (talk | contribs)
Jump to navigation Jump to search

PyMol Wiki Home

You have reached the (new) home of the PyMolWiki, a user-driven web-oriented CMS.

We (will) strive to provide

  • updates on PyMol
  • a stable user-oriented documentation base
  • a thorough treatment of the PyMol program
  • feature rich scripts for general PyMol use

Links of Interest


#############################################################################
# $Id$
#############################################################################

import sys;
import os;
import math;
import re;
import getopt;

from Bio.PDB.PDBParser import PDBParser

import imgWriter
#my imageWriter using GD
#import dali.imageWriter

class point:
        """
        point is a simple representation of a 3D point in space

        """

        def __init__(self, ray = [] ):
                """
                Constructor

                """

                if ( len(ray) != 3 ):
                        print "ERROR: What, so macromolecules are 2-dimensional now?  I don't th
ink so."
                        sys.exit(2)

                # assign instance variables
                self.x = ray[0]
                self.y = ray[1]
                self.z = ray[2]

                # calculate the length from origin
                self.length = math.sqrt( self.x**2 + self.y**2 + self.z**2 )

<npython>

  1. $Id$

import sys; import os; import math; import re; import getopt;

from Bio.PDB.PDBParser import PDBParser

import imgWriter

  1. my imageWriter using GD
  2. import dali.imageWriter


class point:

       """
       point is a simple representation of a 3D point in space
       """
       def __init__(self, ray = [] ):
               """
               Constructor
               """
               if ( len(ray) != 3 ):
                       print "ERROR: What, so macromolecules are 2-dimensional now?  I don't th

ink so."

                       sys.exit(2)
               # assign instance variables
               self.x = ray[0]
               self.y = ray[1]
               self.z = ray[2]
               # calculate the length from origin
               self.length = math.sqrt( self.x**2 + self.y**2 + self.z**2 )

</npython>