to_histogram 1.0.14 → 1.0.15

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/stdout_print.rb +2 -1
  3. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: c7008f7a14f4a5c752f833e60f80357bd2282d8d
4
- data.tar.gz: 6ec8b6c9d8cc9c6a299906e6101b67cb6d5fee94
3
+ metadata.gz: b8e294f1f6f40a95f9222824e814746354411458
4
+ data.tar.gz: 93649a49d4317c8871e2c576e3dc718753b63405
5
5
  SHA512:
6
- metadata.gz: fcfbf59ad4090be49a7e2221279bf8dbcefe6f994ad91f7e81c90ed109098f26ed377d6edae30a5f7048cf406cc71ce4bcf6dbe5b115f0f2870fb2b80f739a17
7
- data.tar.gz: ae9e34f448578d2e86e7e27584fea3201ba64f3e240a78b4a771afd7fe5626fba48270a1013f9cc125e4ec4c593fdd95bdaf04fc97c7a0700fdb425fbefa9579
6
+ metadata.gz: a7cbb0fd3f00d822757cdedcab9e72beab79b200d3f4bb776bd3891f319625af836e193ffa683af0baef788869b5e15ad8e02f7350b8805dd4fcbf4f6be13fc2
7
+ data.tar.gz: 305f250ac56e02b790d03683cc240474d18ec1106274403f44be1be6272b8eafda703c6a8327b20d3c3e75dd00cbae2e636feeef94a5ae029a5d15888207eae3
data/lib/stdout_print.rb CHANGED
@@ -53,7 +53,8 @@ module ToHistogram
53
53
  frequency = b.contents.length
54
54
  percentage = ((frequency.to_f / @histogram.bucket_contents_length) * 100)
55
55
  stars = ''
56
- percentage.round.times { |x| stars << '*' }
56
+
57
+ percentage.ceil.times { |x| stars << '*' }
57
58
 
58
59
  if(i == (@histogram.length - 1))
59
60
  if(b.contents[-1] - b.contents[0] != 0 && (b.contents[-1] - b.contents[0] > @histogram.bucket_width))
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: to_histogram
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.14
4
+ version: 1.0.15
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brett Sykes