Class: Apache::Stat::Inference::T_test
- Inherits:
-
Object
- Object
- Apache::Stat::Inference::T_test
- Defined in:
- lib/ruby-band/apache/stat/inference.rb
Overview
Utility class called by ‘t_test’ method in this same package
Class Method Summary collapse
- .homoscedastic(array_1, array_2) ⇒ Object
- .paired(array_1, array_2) ⇒ Object
- .t(array_1, array_2) ⇒ Object
Class Method Details
.homoscedastic(array_1, array_2) ⇒ Object
89 90 91 92 93 94 95 96 |
# File 'lib/ruby-band/apache/stat/inference.rb', line 89 def self.homoscedastic(array_1,array_2) obj = TTest.new first = array_1.to_java :double second = array_2.to_java :double value = obj.homoscedasticT(first,second) p_value = obj.homoscedasticTTest(first,second) return value, p_value end |
.paired(array_1, array_2) ⇒ Object
98 99 100 101 102 103 104 105 |
# File 'lib/ruby-band/apache/stat/inference.rb', line 98 def self.paired(array_1,array_2) obj = TTest.new first = array_1.to_java :double second =array_2.to_java :double value = obj.pairedT(first,second) p_value = obj.pairedTTest(first,second) return value,p_value end |
.t(array_1, array_2) ⇒ Object
107 108 109 110 111 112 113 114 |
# File 'lib/ruby-band/apache/stat/inference.rb', line 107 def self.t(array_1,array_2) obj = TTest.new first = array_1.to_java :double second =array_2.to_java :double value = obj.t(first,second) p_value =obj.tTest(first,second) return value,p_value end |