Back to index

python-biopython  1.60
Public Member Functions | Public Attributes
test_SCOP_Astral.AstralTests Class Reference

List of all members.

Public Member Functions

def setUp
def testGetSeq
def testConstructWithCustomFile
def testGetDomainsFromFile
def testGetDomainsClustered

Public Attributes

 scop
 astral

Detailed Description

Definition at line 13 of file test_SCOP_Astral.py.


Member Function Documentation

Definition at line 16 of file test_SCOP_Astral.py.

00016 
00017     def setUp(self):
00018         self.scop = Scop(dir_path="SCOP", version="test")
00019         self.astral = Astral(scop=self.scop, dir_path="SCOP", version="test")
00020                 

Definition at line 31 of file test_SCOP_Astral.py.

00031 
00032     def testConstructWithCustomFile(self):
00033         scop = Scop(dir_path="SCOP", version="test")
00034         astral = Astral(scop=scop, astral_file="SCOP/scopseq-test/astral-scopdom-seqres-all-test.fa")
00035         self.assertEqual(astral.getSeqBySid('d3sdha_').tostring(), "AAAAA")
00036         self.assertEqual(astral.getSeqBySid('d4hbib_').tostring(), "KKKKK")
00037                        
         

Here is the call graph for this function:

Definition at line 47 of file test_SCOP_Astral.py.

00047 
00048     def testGetDomainsClustered(self):
00049         domains1 = self.astral.domainsClusteredById(20)
00050         self.assertEqual(len(domains1), 3)
00051         self.assertEqual(domains1[0].sid, "d3sdha_")
00052         self.assertEqual(domains1[1].sid, "d4hbib_")
00053         self.assertEqual(domains1[2].sid, "d5hbia_")
00054                         
00055         domains2 = self.astral.domainsClusteredByEv(1e-15)
00056         self.assertEqual(len(domains2), 1)
00057 
00058         #d1 = scop.getDomainBySid("d3sdha_")
00059         #self.assertEqual(d1.isIn(astral.getHashedDomainsClusteredByPercentId(20))
00060         #self.assertEqual(d1.isIn(astral.getHashedDomainsClusteredByEv(-15))
00061         
00062         
00063         
00064 

Definition at line 38 of file test_SCOP_Astral.py.

00038 
00039     def testGetDomainsFromFile(self):
00040         filename = "SCOP/scopseq-test/astral-scopdom-seqres-sel-gs-bib-20-test.id"
00041         domains = self.astral.getAstralDomainsFromFile(filename)
00042 
00043         self.assertEqual(len(domains), 3)
00044         self.assertEqual(domains[0].sid, "d3sdha_")
00045         self.assertEqual(domains[1].sid, "d4hbib_")
00046         self.assertEqual(domains[2].sid, "d5hbia_")

Definition at line 21 of file test_SCOP_Astral.py.

00021 
00022     def testGetSeq(self):
00023         self.assertEqual(self.astral.getSeqBySid('d3sdha_').tostring(), "AAAAA")
00024         self.assertEqual(self.astral.getSeqBySid('d4hbib_').tostring(), "KKKKK")
00025 
00026         dom = self.scop.getDomainBySid('d3sdha_')
00027         self.assertEqual(self.astral.getSeq(dom).tostring(), "AAAAA")
00028 
00029         
00030         

Here is the call graph for this function:


Member Data Documentation

Definition at line 18 of file test_SCOP_Astral.py.

Definition at line 17 of file test_SCOP_Astral.py.


The documentation for this class was generated from the following file: