def knownSamplesize(seed, data):
     z = Zsc.zsc(seed, data)
     Mar = MarginOfError.marginOfError(seed, data)
     StDe = Stddev.stddev(data)
     value = (z * StDe) / Mar
     sam = Exponential.exponential(value, 2)
     return sam
 def medianskewness(data):
     ni = (Subtraction.difference(Mean.mean(data), Median.median(data)))
     nii = Division.division(ni, Stddev.stddev(data))
     return nii
 def modeskewness(data):
     n = (Subtraction.difference(Mean.mean(data), Mode.mode(data)))
     nn = Division.division(n, Stddev.stddev(data))
     return nn
 def populationcorrelation(data1, data2):
     cov = Covariance.covariance(data1, data2)
     stdDev1 = Stddev.stddev(data1)
     stdDev2 = Stddev.stddev(data2)
     return cov / (stdDev1 * stdDev2)
Exemplo n.º 5
0
 def test_stddev(self):
     self.assertEqual(1.5118578920369088, Stddev.stddev(self.test))
Exemplo n.º 6
0
 def zsc(seed, data):
     X = RandPick.randPickSeed(seed, data)
     mean = Mean.mean(data)
     stddev = Stddev.stddev(data)
     return (X - mean) / stddev
    def samplecorrelation(seed, sample_size, data1, data2):
        dataA = RandPick.randPickListSeed(seed, sample_size, data1)
        dataB = RandPick.randPickListSeed(seed, sample_size, data2)

        return Covariance.covariance(dataA, dataB) / (Stddev.stddev(dataA) * Stddev.stddev(dataB))