TotalDepth.common.statistics¶
-
class
TotalDepth.common.statistics.
LengthDict
¶ Provides statistics about a summary of lengths such as file lengths or logical data lengths.
-
__init__
()¶ Initialize self. See help(type(self)) for accurate signature.
-
__len__
() → int¶ Number of distinct length entries.
-
__getitem__
(item) → int¶ Returns the count of a particular length. Does not write to the dict.
-
min
¶ Minimum length.
-
max
¶ Maximum length.
-
count
¶ Return the total number of entries.
-
zero_count
¶ Return the number of length zero.
-
keys
() → KeysView[int]¶ Return the keys (lengths seen).
-
add
(length: int)¶ Add a length to the summary.
-
reduced_power_2
() → DefaultDict[int, int]¶ Return a histogram with keys reduced to power of 2.
-
histogram_power_of_2
(width: int = 40, bar_char: str = '+') → List[str]¶ Return the count of zero and a histogram of strings of the lengths to power of 2.
-
__weakref__
¶ list of weak references to the object (if defined)
-