streaming_stats 0.1.1 → 0.1.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +27 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4c3251062be9a44205d3dfd587e9c513288b9bb5414a65f68438e4bb7d58110d
|
4
|
+
data.tar.gz: b09feae11073ae734ed94fdd88c2866dc2295a1b3612a5e872185bf1bcc1bc0c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9ff2342d856ea6abb06e48a796dee98b8db37e32cf87de40fdf002d205da59c3c5e4d32bc40dd2f40ef662131703241949bbbe4384784af090889fe55f52e653
|
7
|
+
data.tar.gz: 219138d60059d9bab7afb8d0ad8e202fa0fb71041325da6077ff97bd185a22c4c41846e3bb01e42b3a93eca24e2c4afa6e3d98b956c363dde0c7800f0c0ec424
|
data/README.md
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
# Streaming Stats
|
2
2
|
|
3
|
-

|
3
|
+
 [](https://badge.fury.io/rb/streaming_stats)
|
4
4
|
|
5
5
|
StreamingStats is a Ruby class that takes streaming numeric data
|
6
6
|
and return descriptive statistics with minimal overhead.
|
@@ -56,3 +56,29 @@ my very first Gist: https://gist.github.com/willf/187846.
|
|
56
56
|
The approximate quartile method is a port of [streaming-percentiles-js](https://github.com/sengelha/streaming-percentiles-js).
|
57
57
|
|
58
58
|
How to calculate streaming percentiles is discussed in Steven Englehardt's series, [Calculating Percentiles on Streaming Data](https://www.stevenengelhardt.com/series/calculating-percentiles-on-streaming-data/).
|
59
|
+
|
60
|
+
|
61
|
+
## Script version
|
62
|
+
|
63
|
+
There is also a script version, which will take read numbers from STDIN and produce results on a regular basis:
|
64
|
+
|
65
|
+
```
|
66
|
+
$ bin/streaming_stats --help
|
67
|
+
Prints streaming stats from numbers in $STDIN
|
68
|
+
-help, -h:
|
69
|
+
show help
|
70
|
+
--every x, -n x:
|
71
|
+
display stats every x numbers. default: 5
|
72
|
+
```
|
73
|
+
|
74
|
+
For example:
|
75
|
+
|
76
|
+
```
|
77
|
+
$ ping 8.8.8.8 | ack -oh '\d+\.\d{2,}' --flush | bin/streaming_stats -n 10
|
78
|
+
n v μ σ min max p99
|
79
|
+
10 16.99 19.77 2.61 16.99 26.43 21.36
|
80
|
+
20 25.19 20.56 2.87 16.99 27.13 26.43
|
81
|
+
^C
|
82
|
+
22 19.01 20.4 2.79 16.99 27.13 26.43
|
83
|
+
|
84
|
+
```
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: streaming_stats
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Will Fitzgerald
|
@@ -30,7 +30,7 @@ files:
|
|
30
30
|
- streaming_stats.rb
|
31
31
|
- test/test_helper.rb
|
32
32
|
- test/test_streaming_stats.rb
|
33
|
-
homepage: https://github.com/willf/
|
33
|
+
homepage: https://github.com/willf/streaming_stats_ruby
|
34
34
|
licenses:
|
35
35
|
- MIT
|
36
36
|
metadata: {}
|
@@ -49,7 +49,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
49
49
|
- !ruby/object:Gem::Version
|
50
50
|
version: '0'
|
51
51
|
requirements: []
|
52
|
-
rubygems_version: 3.
|
52
|
+
rubygems_version: 3.2.3
|
53
53
|
signing_key:
|
54
54
|
specification_version: 4
|
55
55
|
summary: Calculates descriptive statistics from streams
|