Class: Hyrax::Statistics::Users::OverTime

Inherits:
OverTime
  • Object
show all
Defined in:
app/services/hyrax/statistics/users/over_time.rb

Instance Method Summary collapse

Methods inherited from OverTime

#initialize

Constructor Details

This class inherits a constructor from Hyrax::Statistics::OverTime

Instance Method Details

#pointsObject

Overridden to do a noncumulative query


6
7
8
9
10
11
12
13
14
15
# File 'app/services/hyrax/statistics/users/over_time.rb', line 6

def points
  Enumerator.new(size) do |y|
    x = @x_min
    while x <= @x_max
      bottom = x
      x += @delta_x.days
      y.yield [@x_output.call(x), point(bottom, x)]
    end
  end
end