health_stats 0.1.0 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- data/VERSION +1 -1
- data/health_stats.gemspec +1 -1
- data/lib/health_stats/percentile.rb +5 -3
- metadata +2 -2
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.1.
|
1
|
+
0.1.1
|
data/health_stats.gemspec
CHANGED
@@ -13,16 +13,18 @@ module HealthStats
|
|
13
13
|
end
|
14
14
|
|
15
15
|
month_age = age_in_months
|
16
|
-
lms_value = nil
|
17
16
|
|
18
17
|
return unless stat_value && month_age && gender
|
19
|
-
return if month_age < 24.0 || month_age > 241.0
|
20
18
|
|
19
|
+
lms_value = nil
|
21
20
|
chart = CDC.data[stat][gender.to_sym]
|
22
|
-
|
21
|
+
|
22
|
+
return if (month_age < chart.keys.min) || month_age > 240.0
|
23
|
+
|
23
24
|
while lms_value.nil?
|
24
25
|
lms_value = chart[month_age]
|
25
26
|
month_age -= 0.5
|
27
|
+
return if month_age < 0
|
26
28
|
end
|
27
29
|
|
28
30
|
# I feel dirty.
|