heatmap 0.1.0 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- data/.travis.yml +4 -1
- data/examples/README.md +2 -2
- data/heatmap.gemspec +2 -2
- data/lib/heatmap/map.rb +2 -1
- data/lib/heatmap/version.rb +1 -1
- data/test/test_heatmap.rb +1 -1
- metadata +3 -3
data/.travis.yml
CHANGED
data/examples/README.md
CHANGED
@@ -20,7 +20,7 @@ map.output('simple.png')
|
|
20
20
|
|
21
21
|
Output image:
|
22
22
|
|
23
|
-
![Simple](simple.png)
|
23
|
+
![Simple](https://raw.github.com/tjackiw/heatmap/master/examples/simple.png)
|
24
24
|
|
25
25
|
### External data example
|
26
26
|
|
@@ -43,4 +43,4 @@ map.output('large.png')
|
|
43
43
|
|
44
44
|
Output image:
|
45
45
|
|
46
|
-
![Simple](large.png)
|
46
|
+
![Simple](https://raw.github.com/tjackiw/heatmap/master/examples/large.png)
|
data/heatmap.gemspec
CHANGED
@@ -5,11 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = "heatmap"
|
8
|
-
s.version = "0.1.
|
8
|
+
s.version = "0.1.1"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Thiago Jackiw"]
|
12
|
-
s.date = "2013-
|
12
|
+
s.date = "2013-02-06"
|
13
13
|
s.description = " Simple Heatmap generator in Ruby. (Requires ImageMagick) "
|
14
14
|
s.email = "tjackiw@gmail.com"
|
15
15
|
s.extra_rdoc_files = [
|
data/lib/heatmap/map.rb
CHANGED
@@ -4,7 +4,8 @@ module Heatmap
|
|
4
4
|
attr_accessor :area
|
5
5
|
|
6
6
|
def initialize
|
7
|
-
|
7
|
+
location = `which convert` || `where convert`
|
8
|
+
raise(RuntimeError, "You need to have ImageMagick installed!") if location.nil? || location.strip.empty?
|
8
9
|
@area = []
|
9
10
|
end
|
10
11
|
|
data/lib/heatmap/version.rb
CHANGED
data/test/test_heatmap.rb
CHANGED
@@ -4,7 +4,7 @@ class TestHeatmap < Test::Unit::TestCase
|
|
4
4
|
|
5
5
|
should "properly generate a heatmap" do
|
6
6
|
map = Heatmap::Map.new
|
7
|
-
10.times{|i| map << Heatmap::Area.new(rand(
|
7
|
+
10.times{|i| map << Heatmap::Area.new(rand(100), rand(100))}
|
8
8
|
assert map.output(example_png_file)
|
9
9
|
end
|
10
10
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: heatmap
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.1
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2013-
|
12
|
+
date: 2013-02-06 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: shoulda
|
@@ -127,7 +127,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
127
127
|
version: '0'
|
128
128
|
segments:
|
129
129
|
- 0
|
130
|
-
hash:
|
130
|
+
hash: 2646434800055512285
|
131
131
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
132
132
|
none: false
|
133
133
|
requirements:
|