xb5_structural_stats (xb5 v1.0.1)
View SourceStructural statistics about a B-tree.
This is primarily intended for debugging and testing.
Summary
Types
-type count_per_node() :: [{node_type(), non_neg_integer()}, ...].
-type node_type() :: internal4 | internal3 | internal2 | internal1 | leaf4 | leaf3 | leaf2 | leaf1.
-type stat() :: {height, non_neg_integer()} | {node_counts, count_per_node()} | {node_percentages, percent_per_node()} | {total_keys, non_neg_integer()} | {key_percentages, percent_per_node()} | {avg_keys_per_node, undefined | float()} | {avg_keys_per_internal_node, undefined | float()} | {avg_keys_per_leaf_node, undefined | float()}.
-type t() :: [stat(), ...].