メインコンテンツへスキップ

studentTTest

導入バージョン: v21.1.0 2 つの母集団から得られたサンプルに対してスチューデントの t 検定を適用します。 両方のサンプルの値は sample_data カラムに格納されます。sample_index が 0 の場合、その行の値は 1 つ目の母集団のサンプルに属します。それ以外の場合は、2 つ目の母集団のサンプルに属します。 帰無仮説は、母集団の平均が等しいというものです。分散が等しい正規分布を仮定します。 関連項目 構文
studentTTest([confidence_level])(sample_data, sample_index)
パラメータ
  • confidence_level — 任意。信頼区間の計算に使用する信頼水準。Float
引数
  • sample_data — サンプルデータ。Integer または Float または Decimal
  • sample_index — サンプルインデックス。Integer
戻り値 2 つまたは 4 つの要素を持つタプルを返します (任意の confidence_level が指定されている場合) 。計算された t 統計量、計算された p 値、[計算された信頼区間の下限]、[計算された信頼区間の上限]。Tuple(Float64, Float64) または Tuple(Float64, Float64, Float64, Float64) 基本的な使い方
Query
SELECT studentTTest(sample_data, sample_index) FROM student_ttest;
Response
┌─studentTTest(sample_data, sample_index)───┐
│ (-0.21739130434783777,0.8385421208415731) │
└───────────────────────────────────────────┘
関連項目
最終更新日 2026年6月10日