Exemple #1
0
def cintreval(list):
    try:
        mean_var = mean(list)
        cin = 0.95
        value_of_z = (1-cin) / 2
        stdev_var = stdev(list)
        n = sqrt(len(list))
        result = [mean_var - value_of_z*stdev_var / n, mean_var + value_of_z*stdev_var / n]
        return result
    except Exception as e:
        print("Error with Cintreval")
        return [0,0]
def Variance_of_population_proportion(list):

    listx = []
    listy = []
    std = stdev(list)

    for row in range(0,len(list)):
        if list[row] <= std:
            listx.append(int(list[row]))
        else:
            listy.append(int(list[row]))


    p = (len(listx)*100/len(list))/100
    q = 1 - p


    c = (p*q)/len(list)
    return c
Exemple #3
0
def zscore(z, list):
    c = (z * stdev(list)) + mean(list)
    return c
Exemple #4
0
 def stdev_(self, list):
     self.result = stdev(list)
     return self.result
def samplestdev(list):
    s = 50
    r = Sample(list, s)
    c = stdev(r)
    return c
def population_correlation_coefficient(a, b):

    x = cov(a, b)
    y = stdev(a) * stdev(b)
    c = x / y
    return c