lib/roi/rentability.rb in roi_calculator-0.1.2 vs lib/roi/rentability.rb in roi_calculator-0.1.3
- old
+ new
@@ -62,10 +62,10 @@
0.upto(filtered.size - days).map do |low|
series = filtered.slice(low, days + 1)
vol = MathUtil.volatility(series)
date = dates_with_position.fetch(low + days) { dates_with_position.last }
- [date.to_time.to_i, vol] if date
+ [date.to_s(:db), vol] if date
end
end
def to_a
dates_with_position.map do |date|