예제 #1
0
    def setUp(self):
        self.pdssuite = []
        self.pyssuite = []

        data = np.matrix(list(csv.reader(open("test.csv", "r"))))
        data = cs.dataFormat(data)
        self.pdssuite.append(cs.Cusum(data[0], 1000, fcn = "pds", para = (1,"twoside", 36)))
        self.pdssuite.append(cs.Cusum(data[1], 1000, fcn = "pds", para = (1,"upper", 36)))
        self.pdssuite.append(cs.Cusum(data[2], 1000, fcn = "pds", para = (1,"lower", 36)))
        self.pyssuite.append(cs.Cusum(data[3], 1000, fcn = "pys", para = (7.5, 0.5, 0., 0.9, 1.0)))
예제 #2
0
    def setUp(self):
        self.pdssuite = []
        self.pyssuite = []

        self.pdscross = {0:ts.Date('M', '2002-11'), 1:ts.Date('M', '2002-2'), 2:ts.Date('M', '2001-12')}
        self.pyscross = {0:ts.Date('M', '1999-10')}
        
        data = np.matrix(list(csv.reader(open("test.csv", "r"))))
        data = cs.dataFormat(data)
        self.pdssuite.append(cs.Cusum(data[0], 4, fcn = "pds", para = (1,"twoside", 36)))
        self.pdssuite.append(cs.Cusum(data[1], 4, fcn = "pds", para = (1,"upper", 36)))
        self.pdssuite.append(cs.Cusum(data[2], 4, fcn = "pds", para = (1,"lower", 36)))
        self.pyssuite.append(cs.Cusum(data[3], 4, fcn = "pys", para = (7.5, 0.5, 0., 0.9, 1.0)))
예제 #3
0
 def setUp(self):
     data = np.matrix(list(csv.reader(open("handletest.csv", "r"))))
     self.data = cs.dataFormat(data)
     self.na = cs.Cusum(self.data[0], 4, fcn = "pds", para = (1, "twoside", 36))