예제 #1
0
    def __init__(self, prob=.5, size=20):

        self.n = size
        self.p = prob

        Distribution.__init__(self, self.calculate_mean(),
                              self.calculate_stdev())
예제 #2
0
    def __init__(self, prob=.5, size=20):
        # TODO: store the probability of the distribution in an instance variable p
        self.p = prob

        # TODO: store the size of the distribution in an instance variable n
        self.n = size

        # TODO: Now that you know p and n, you can calculate the mean and standard deviation
        #       Use the calculate_mean() and calculate_stdev() methods to calculate the
        #       distribution mean and standard deviation
        self.mean = self.calculate_mean()

        self.stdev = self.calculate_stdev()
        #       Then use the init function from the Distribution class to initialize the
        #       mean and the standard deviation of the distribution
        Distribution.__init__(self, self.mean, self.stdev)
예제 #3
0
 def __init__(self, parmA,parmB):
     Distribution.__init__(self)
     self.parmA = parmA
     self.parmB = parmB
예제 #4
0
 def __init__(self, parmM,parmG):
     Distribution.__init__(self)
     self.parmM = parmM
     self.parmG = parmG
예제 #5
0
 def __init__(self, parmM, parmG):
     Distribution.__init__(self)
     self.parmM = parmM
     self.parmG = parmG
예제 #6
0
    def __init__(self, mu=0, sigma=1):

        Distribution.__init__(self, mu, sigma)
예제 #7
0
파일: discrete.py 프로젝트: iosp/robil2
 def __init__(self,listOFparms):
     Distribution.__init__()
예제 #8
0
 def __init__(self, parmA, parmB):
     Distribution.__init__(self)
     self.parmA = parmA
     self.parmB = parmB
예제 #9
0
 def __init__(self, Map={}):
     Distribution.__init__(self)
     #map is a python dictionary{[time,count]..}
     self.map = Map
예제 #10
0
 def __init__(self,Map = {}):
     Distribution.__init__(self)
      #map is a python dictionary{[time,count]..}    
     self.map = Map