We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent e36459e commit 2ca77b8Copy full SHA for 2ca77b8
plotille.py
@@ -215,7 +215,8 @@ def _hist(X, bins): # noqa: N803
215
counts: List[int] The counts for all bins.
216
bins: List[float] The range for each bin: bin `i` is in [bins[i], bins[i+1])
217
'''
218
- xmin, xmax = min([0] + X), max([1] + X)
+ xmin = min(X) if len(X) > 0 else 0
219
+ xmax = max(X) if len(X) > 0 else 1
220
xwidth = abs((xmax - xmin) / bins)
221
222
y = [0] * bins
0 commit comments