heatmap 0.1.0 → 0.1.1
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.
- 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
|
-

|
23
|
+

|
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
|
-

|
46
|
+

|
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:
|