Class: Skab::Output::Summary

Inherits:
Object
  • Object
show all
Defined in:
lib/skab/output/summary.rb

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(out) ⇒ Summary

Returns a new instance of Summary.



4
5
6
# File 'lib/skab/output/summary.rb', line 4

def initialize(out)
  @out = out
end

Class Method Details

.helpObject



15
16
17
18
19
20
21
# File 'lib/skab/output/summary.rb', line 15

def self.help
  <<-HELP
Usage: skab summary [model] [parameters]
\tOutputs a summary of the whole statistical analysis conducted on A and
\tB, using the specified model.
  HELP
end

Instance Method Details

#output(model) ⇒ Object



8
9
10
11
12
13
# File 'lib/skab/output/summary.rb', line 8

def output(model)
  min = model.percentile(0.05)
  max = model.percentile(0.95)

  @out.puts "The difference is located between #{min} and #{max} (90% confidence)"
end