Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(14)  |  Call(14)  |  Derive(0)  |  Import(0)

src/p/y/Pymol-script-repo-HEAD/modules/pdb2pqr/contrib/numpy-1.1.0/numpy/doc/swig/test/testArray.py   Pymol-script-repo(Download)
    def setUp(self):
        self.length = 5
        self.array1 = Array.Array1(self.length)
 
    def testConstructor0(self):
        "Test Array1 default constructor"
        a = Array.Array1()
    def testConstructor2(self):
        "Test Array1 array constructor"
        na = np.arange(self.length)
        aa = Array.Array1(na)
        self.failUnless(isinstance(aa, Array.Array1))
 
    def testConstructor3(self):
        "Test Array1 copy constructor"
        for i in range(self.array1.length()): self.array1[i] = i
        arrayCopy = Array.Array1(self.array1)
        a = np.arange(n, dtype="l")
        for i in range(m):
            array1.append(Array.Array1(i*a))
        for i in range(m):
            self.array2[i] = array1[i]

src/n/u/numpy-1.8.1/doc/swig/test/testArray.py   numpy(Download)
    def setUp(self):
        self.length = 5
        self.array1 = Array.Array1(self.length)
 
    def testConstructor0(self):
        "Test Array1 default constructor"
        a = Array.Array1()
    def testConstructor2(self):
        "Test Array1 array constructor"
        na = np.arange(self.length)
        aa = Array.Array1(na)
        self.failUnless(isinstance(aa, Array.Array1))
 
    def testConstructor3(self):
        "Test Array1 copy constructor"
        for i in range(self.array1.length()): self.array1[i] = i
        arrayCopy = Array.Array1(self.array1)
        a = np.arange(n, dtype="l")
        for i in range(m):
            array1.append(Array.Array1(i*a))
        for i in range(m):
            self.array2[i] = array1[i]