stream_stats 0.0.3

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,6 @@
1
+ require 'oozie-client/version'
2
+ require 'stream_stats/stream_stats'
3
+ require 'stream_stats/stream'
4
+
5
+ module StreamStats
6
+ end
@@ -0,0 +1,17 @@
1
+ module StreamStats
2
+ class Stream
3
+
4
+ def get_quantiles
5
+ Hash[@quantiles.map do |q|
6
+ [q, quantile(q)]
7
+ end]
8
+ end
9
+
10
+ def inspect
11
+ attr_list = [:count, :sum, :min, :max, :mean, :stddev].map do |method|
12
+ "#{method.to_s}: #{self.send(method)}"
13
+ end * ', '
14
+ "#{self.to_s} {#{attr_list}, quantiles: #{get_quantiles.to_s}}"
15
+ end
16
+ end
17
+ end
@@ -0,0 +1,4 @@
1
+ class StreamStats
2
+ VERSION = "0.0.3"
3
+ end
4
+
@@ -0,0 +1,15 @@
1
+ # -*- encoding: utf-8 -*-
2
+ require File.expand_path('../lib/stream_stats/version', __FILE__)
3
+
4
+ Gem::Specification.new do |s|
5
+ s.name = 'stream_stats'
6
+ s.version = '0.0.1'
7
+ s.summary = "Stream Statistics"
8
+ s.description = "Compute statistics on stream data"
9
+ s.version = StreamStats::VERSION
10
+ s.authors = ["Neville Kadwa"]
11
+ s.email = ["neville@kadwa.com"]
12
+ s.files = `git ls-files`.split($\)
13
+ s.homepage = 'http://github.com/kadwanev/stream_stats'
14
+ s.extensions = ['ext/stream_stats/extconf.rb']
15
+ end
metadata ADDED
@@ -0,0 +1,57 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: stream_stats
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.3
5
+ platform: ruby
6
+ authors:
7
+ - Neville Kadwa
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2013-06-13 00:00:00.000000000 Z
12
+ dependencies: []
13
+ description: Compute statistics on stream data
14
+ email:
15
+ - neville@kadwa.com
16
+ executables: []
17
+ extensions:
18
+ - ext/stream_stats/extconf.rb
19
+ extra_rdoc_files: []
20
+ files:
21
+ - README.rdoc
22
+ - ext/stream_stats/cm_quantile.c
23
+ - ext/stream_stats/cm_quantile.h
24
+ - ext/stream_stats/extconf.rb
25
+ - ext/stream_stats/heap.c
26
+ - ext/stream_stats/heap.h
27
+ - ext/stream_stats/stream_stats.c
28
+ - ext/stream_stats/timer.c
29
+ - ext/stream_stats/timer.h
30
+ - lib/stream_stats.rb
31
+ - lib/stream_stats/stream.rb
32
+ - lib/stream_stats/version.rb
33
+ - stream_stats.gemspec
34
+ homepage: http://github.com/kadwanev/stream_stats
35
+ licenses: []
36
+ metadata: {}
37
+ post_install_message:
38
+ rdoc_options: []
39
+ require_paths:
40
+ - lib
41
+ required_ruby_version: !ruby/object:Gem::Requirement
42
+ requirements:
43
+ - - '>='
44
+ - !ruby/object:Gem::Version
45
+ version: '0'
46
+ required_rubygems_version: !ruby/object:Gem::Requirement
47
+ requirements:
48
+ - - '>='
49
+ - !ruby/object:Gem::Version
50
+ version: '0'
51
+ requirements: []
52
+ rubyforge_project:
53
+ rubygems_version: 2.0.3
54
+ signing_key:
55
+ specification_version: 4
56
+ summary: Stream Statistics
57
+ test_files: []