SimpleOutput 1.0.7 → 1.0.8
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/lib/simpleplot.rb +7 -6
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ce1c4995f98117212b211c6048a9de3c6edf3799
|
4
|
+
data.tar.gz: 157a00bbd81473cd5cf839adac55a57066ea5a2a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 20fefb6091af75a1ff1fa2d31eb4b5d9ef6b128925c9f2e5c0ded03e50d915dbf2303f8edd26e549de833ef9a86f30138619790a2df4d189ad527e361623d4cb
|
7
|
+
data.tar.gz: d4833aec0f48ae47e73be2ed4e19bc828e88d7b70036cb75d1103ba7c5ef066e265fd7a96f12f5cfb06ed96a58b70c4d082e819a14a35ad078881a284674f472
|
data/lib/simpleplot.rb
CHANGED
@@ -126,13 +126,14 @@ class SimplePlot < SimpleOutput::SimpleOutputPlugin
|
|
126
126
|
plot.xlabel @metadata[set_name]['xlabel']
|
127
127
|
plot.ylabel @metadata[set_name]['ylabel']
|
128
128
|
plot.data = []
|
129
|
-
|
129
|
+
max = @metadata[set_name]['ymax']
|
130
|
+
min = @metadata[set_name]['ymin']
|
131
|
+
if min == max
|
132
|
+
max = min + 1
|
133
|
+
end
|
130
134
|
if @metadata[set_name]['histogram']
|
131
135
|
size = @metadata[set_name]['length']
|
132
|
-
bins = @metadata[set_name]['bincount']
|
133
|
-
max = @metadata[set_name]['ymax']
|
134
|
-
min = @metadata[set_name]['ymin']
|
135
|
-
|
136
|
+
bins = @metadata[set_name]['bincount']
|
136
137
|
width = (max.to_f-min.to_f).to_f/bins.to_f
|
137
138
|
#bins = size.to_f/width.to_f
|
138
139
|
plot.yrange '[0:]'
|
@@ -144,7 +145,7 @@ class SimplePlot < SimpleOutput::SimpleOutputPlugin
|
|
144
145
|
plot.set('style', 'fill solid 0.5')
|
145
146
|
else
|
146
147
|
plot.xrange "[#{@metadata[set_name]['xmin']}:#{@metadata[set_name]['xmax']}]"
|
147
|
-
plot.yrange "[#{
|
148
|
+
plot.yrange "[#{min}:#{max}]"
|
148
149
|
end
|
149
150
|
series.each_with_index do |line, index|
|
150
151
|
|