health_stats 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/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.
|