Class: Num4HypothTestLib::TwoSideTestLib

Inherits:
Object
  • Object
show all
Defined in:
lib/num4hypothtst.rb

Overview

両側検定

Instance Method Summary collapse

Constructor Details

#initialize ⇒ TwoSideTestLib

Returns a new instance of TwoSideTestLib.



14
15
16
# File 'lib/num4hypothtst.rb', line 14

def initialize
    @hypothTest = TwoSideTest.getInstance()
end

Instance Method Details

#chi2DistTest(statistic, df, a) ⇒ Object

階2乗検定

return [boolean] 検定結果(true:棄却域内 false:棄却域外)

Parameters:

  • statistic (double) —

    統計量

  • df (int) —

    自由度

  • a (double) —

    有意水準



34
35
36
# File 'lib/num4hypothtst.rb', line 34

def chi2DistTest(statistic, df, a)
    return @hypothTest.chi2DistTest(statistic, df, a)
end

#fDistTest(statistic, nf, df, a) ⇒ Object

F検定

return [boolean] 検定結果(true:棄却域内 false:棄却域外)

Parameters:

  • statistic (double) —

    統計量

  • nf (int) —

    自由度

  • df (int) —

    自由度

  • a (double) —

    有意水準



54
55
56
# File 'lib/num4hypothtst.rb', line 54

def fDistTest(statistic, nf, df, a)
    return @hypothTest.fDistTest(statistic, nf, df, a)
end

#normDistest(statistic, a) ⇒ Object

標準正規分布検定

return [boolean] 検定結果(true:棄却域内 false:棄却域外)

Parameters:

  • statistic (double) —

    統計量

  • a (double) —

    有意水準



43
44
45
# File 'lib/num4hypothtst.rb', line 43

def normDistest(statistic, a)
    return @hypothTest.normDistest(statistic, a)
end

#tDistTest(statistic, df, a) ⇒ Object

T検定

return [boolean] 検定結果(true:棄却域内 false:棄却域外)

Parameters:

  • statistic (double) —

    統計量

  • df (int) —

    自由度

  • a (double) —

    有意水準



24
25
26
# File 'lib/num4hypothtst.rb', line 24

def tDistTest(statistic, df, a)
    return @hypothTest.tDistTest(statistic, df, a)
end