Skip to content
Permalink
Browse files

[processing] Make basic statistics translatable

  • Loading branch information
m-kuhn committed Feb 26, 2016
1 parent fb7c683 commit 3e5e108b1a4dd2c861c3c011bbf344f88d590be7
@@ -147,24 +147,24 @@ def processAlgorithm(self, progress):
iqr = stat.interQuartileRange()

data = []
data.append('Analyzed layer: ' + layer.name())
data.append('Analyzed field: ' + fieldName)
data.append('Count: ' + unicode(count))
data.append('Unique values: ' + unicode(uniqueValue))
data.append('Minimum value: ' + unicode(minValue))
data.append('Maximum value: ' + unicode(maxValue))
data.append('Range: ' + unicode(rValue))
data.append('Sum: ' + unicode(sumValue))
data.append('Mean value: ' + unicode(meanValue))
data.append('Median value: ' + unicode(medianValue))
data.append('Standard deviation: ' + unicode(stdDevValue))
data.append('Coefficient of Variation: ' + unicode(cvValue))
data.append('Minority (rarest occurring value): ' + unicode(minority))
data.append('Majority (most frequently occurring value): ' + unicode(majority))
data.append('First quartile: ' + unicode(firstQuartile))
data.append('Third quartile: ' + unicode(thirdQuartile))
data.append('NULL (missed) values: ' + unicode(nullValues))
data.append('Interquartile Range (IQR): ' + unicode(iqr))
data.append(self.tr('Analyzed layer: {}').format(layer.name()))
data.append(self.tr('Analyzed field: {}').format(fieldName))
data.append(self.tr('Count: {}').format(count))
data.append(self.tr('Unique values: {}').format(uniqueValue))
data.append(self.tr('Minimum value: {}').format(minValue))
data.append(self.tr('Maximum value: {}').format(maxValue))
data.append(self.tr('Range: {}').format(rValue))
data.append(self.tr('Sum: {}').format(sumValue))
data.append(self.tr('Mean value: {}').format(meanValue))
data.append(self.tr('Median value: {}').format(medianValue))
data.append(self.tr('Standard deviation: {}').format(stdDevValue))
data.append(self.tr('Coefficient of Variation: {}').format(cvValue))
data.append(self.tr('Minority (rarest occurring value): {}').format(minority))
data.append(self.tr('Majority (most frequently occurring value): {}').format(majority))
data.append(self.tr('First quartile: {}').format(firstQuartile))
data.append(self.tr('Third quartile: {}').format(thirdQuartile))
data.append(self.tr('NULL (missing) values: {}').format(nullValues))
data.append(self.tr('Interquartile Range (IQR): {}').format(iqr))

self.createHTML(outputFile, data)

@@ -125,15 +125,15 @@ def processAlgorithm(self, progress):
uniqueValues = vector.getUniqueValuesCount(layer, index)

data = []
data.append('Analyzed layer: ' + layer.name())
data.append('Analyzed field: ' + fieldName)
data.append('Minimum length: ' + unicode(minValue))
data.append('Maximum length: ' + unicode(maxValue))
data.append('Mean length: ' + unicode(meanValue))
data.append('Filled values: ' + unicode(filledValues))
data.append('NULL (missed) values: ' + unicode(nullValues))
data.append('Count: ' + unicode(count))
data.append('Unique: ' + unicode(uniqueValues))
data.append(self.tr('Analyzed layer: {}').format(layer.name()))
data.append(self.tr('Analyzed field: {}').format(fieldName))
data.append(self.tr('Minimum length: {}').format(minValue))
data.append(self.tr('Maximum length: {}').format(maxValue))
data.append(self.tr('Mean length: {}').format(meanValue))
data.append(self.tr('Filled values: {}').format(filledValues))
data.append(self.tr('NULL (missing) values: {}').format(nullValues))
data.append(self.tr('Count: {}').format(count))
data.append(self.tr('Unique: {}').format(uniqueValues))

self.createHTML(outputFile, data)

@@ -16,6 +16,6 @@
<p>Majority (most frequently occurring value): -0.123</p>
<p>First quartile: -0.0615</p>
<p>Third quartile: 0.0615</p>
<p>NULL (missed) values: 1</p>
<p>NULL (missing) values: 1</p>
<p>Interquartile Range (IQR): 0.123</p>
</body></html>
@@ -6,7 +6,7 @@
<p>Maximum length: 4.0</p>
<p>Mean length: 4.0</p>
<p>Filled values: 3</p>
<p>NULL (missed) values: 1</p>
<p>NULL (missing) values: 1</p>
<p>Count: 4</p>
<p>Unique: 2</p>
</body></html>

0 comments on commit 3e5e108

Please sign in to comment.
You can’t perform that action at this time.