computeCountsStream method
Implementation
Future<List<BinCount<T>>> computeCountsStream(Stream<T> data) async {
final bins = this.map((e) => BinCount<T>(e, 0)).toList();
await for (final T item in data) {
bins.addSample(item);
}
return bins;
}