Exemplo n.º 1
0
 def test_scarr(self):
     inp = np.array([np.arange(100), np.arange(100, 200)]).reshape(100, 2)
     inp95 = scarr(inp, "sig95")
     inpwt = scarr(inp, "whiten")
     aequal(inp95[:, 0], inp95[:, 1])
     equal(inp95[1, 1], 0.0105715990067)
     assert (inpwt[:, 0] - inpwt[:, 1] < 0).all()
Exemplo n.º 2
0
 def test_loadarr(self):
     k, a = load_arr(os.path.join(pkg_dir, "data", "test_ab_cnt.arr"))
     assert k[0] == "dnase:a"
     aequal(a[0], [
         0., 2., 1., 2., 0., 0., 0., 12., 0., 2., 0., 2., 0., 0., 0., 0.,
         0., 0., 0., 1., 1., 1., 1., 0.
     ])
Exemplo n.º 3
0
 def test_scarr(self):
     inp = np.array([np.arange(100),
                     np.arange(100, 200)]).reshape(100,2)
     inp95 = scarr(inp, "sig95")
     inpwt = scarr(inp, "whiten")
     aequal(inp95[:,0], inp95[:,1])
     equal(inp95[1,1], 0.0105715990067)
     assert (inpwt[:,0] - inpwt[:,1] < 0).all()
Exemplo n.º 4
0
 def test_loadarr(self):
     k,a = load_arr(os.path.join(pkg_dir, "data", "test_ab_cnt.arr"))
     assert k[0] == "dnase:a"
     aequal(a[0], [0.,2.,1.,2.,0.,0.,0.,12.,0.,2.,0.,2.,0.,0.,0.,0.,0.,0.,0.,1.,1.,1.,1.,0.])