Module: Experiment::Stats

Extended by:
Descriptive
Defined in:
lib/experiment/stats/descriptive.rb

Defined Under Namespace

Modules: Descriptive

Class Method Summary collapse

Methods included from Descriptive

mean, median, range, standard_deviation, sum, variance, z_score, z_scores

Class Method Details

.monkey_patch!Object

Monkey pathces the Array class to accept the methods in this class as it’s own - so instead of ‘Stats::variance([1, 2, 3])` you can call [1, 2, 3].variance



49
50
51
# File 'lib/experiment/stats/descriptive.rb', line 49

def monkey_patch!
  Array.send :include, Descriptive
end